31 Commits

Author SHA1 Message Date
Jeffrey C. Ollie
0778c67429 gtk: refactor gtk & adw notebook implementations
Put GTK and libadwaita notebook implementations into separate structs/
files for clarity.
2025-01-02 15:21:11 -06:00
Leigh Oliver
034f79cfa2 fix(gtk): fix segfault/bus error on ctrl+d 2024-12-28 10:55:13 +00:00
Tristan Partin
73bb2bb9bc apprt/gtk: add gtk-tabs-location=hidden
This is only supported on libadwaita. Instead of the normal tab overview
button, we will use an AdwTabButton[0].

Link: https://gnome.pages.gitlab.gnome.org/libadwaita/doc/1.6/class.TabButton.html [0]
Signed-off-by: Tristan Partin <tristan@partin.io>
2024-12-14 12:40:11 -06:00
Tristan Partin
9c25811576 apprt/gtk: handle pwd action
Use it as a tooltip for the tab.

Signed-off-by: Tristan Partin <tristan@partin.io>
2024-11-16 15:20:53 -06:00
axdank
520dda65cb apply review changes 2024-10-25 08:07:11 -03:00
axdank
465d60def8 gui: add move_current_tab action 2024-10-24 00:01:54 -03:00
Mitchell Hashimoto
38db305d29 Merge pull request #2289 from jcollie/ghostty-adwaita-version
gtk/adw: conditional tab keybindings
2024-09-23 21:11:32 -07:00
Jeffrey C. Ollie
8186e95902 gtk/adw: perform version check at both comptime and runtime 2024-09-23 11:41:39 -05:00
Jeffrey C. Ollie
2805657213 gtk/adw: conditional tab keybindings
adw_tab_view_remove_shortcuts (and related APIs) was added in libadwaita
1.2.0.
2024-09-23 10:31:01 -05:00
Paul Berg
2033e59240 apprt/gtk: set tabs reorderable/detachable on GtkNotebook 2024-09-23 10:16:10 +02:00
Yi Ming
2894e78cbe adw: disable all of the default shortcuts 2024-09-19 15:15:47 +08:00
Paul Berg
89506e5933 gtk: prevent invalid call to adw_tab_view_get_page_position
Creating the first tab would call adw_tab_view_get_page_position with a null page.
2024-09-16 18:10:57 +02:00
Mitchell Hashimoto
4a539cf4c9 apprt/gtk: style tweaks 2024-09-13 09:51:51 -07:00
Paul Berg
1037265cd9 apprt/gtk: make Notebook.create not depend on parent box 2024-09-13 09:44:41 -07:00
Paul Berg
b935c7d46c apprt/gtk: remove adw_tab_page from tab 2024-09-13 15:32:17 +02:00
Paul Berg
3dc4185d50 apprt/gtk: respect window-new-tab-position again 2024-09-13 11:37:23 +02:00
Mitchell Hashimoto
fced4370d3 apprt/gtk: some tweaks, avoid uninitialized memory access, use optionals 2024-09-12 16:14:48 -07:00
Tristan Partin
f35671417c apprt/gtk: use AdwTabOverview
An additional way to manage tabs.

Signed-off-by: Tristan Partin <tristan@partin.io>
2024-09-12 15:59:07 -07:00
Max Guppy
b6198e37f2 Reapply "Merge pull request #1690 from TheOnlyMrCat/gtk_opacity"
This reverts commit 57bf0b08ffe04578feb087fab739a48543c0ac75.
2024-09-12 13:36:31 +10:00
Mitchell Hashimoto
37ba052913 apprt/gtk: cleaup final notebook page on libadw 1.3.x 2024-09-11 10:44:30 -07:00
Mitchell Hashimoto
8186a8835b apprt/gtk: scope comptime to only one 2024-09-11 10:17:41 -07:00
Mitchell Hashimoto
c27f427e02 apprt/gtk: the comptimeEnabled check is redundant 2024-09-11 09:50:37 -07:00
Mitchell Hashimoto
afc95fefe2 apprt/gtk: use adwaita helpers, move out some complicated logic 2024-09-11 09:38:05 -07:00
Paul Berg
7aa6b0008a adw: add support for gtk-tabs-location = bottom
this falls back to top when using either right or left.
2024-09-11 17:23:56 +02:00
Paul Berg
0c286a049a gtk: add adwaita banner 2024-09-11 15:42:31 +02:00
Paul
bdf618d7af gtk: adw toolbar view
gate toolbar view on ADWAITA_MINOR >= 4

use the right destructor on window creation errors
2024-09-11 15:42:31 +02:00
Paul Berg
618a7a3fea adw: update window title on selected page change 2024-09-11 15:42:31 +02:00
Paul Berg
439988930d gtk: respect wide-tabs option 2024-09-11 15:42:31 +02:00
Paul Berg
5327daac04 adw: implement next/previous 2024-09-11 15:42:31 +02:00
Paul Berg
9c8a9f3d6b adw: respect gtk-wide-tabs
update
2024-09-11 15:42:05 +02:00
Paul
42c93d89fc adw: move notebook to its own file 2024-09-11 15:42:03 +02:00