5828 Commits

Author SHA1 Message Date
Gregory Anders
21e40e9842 config: interpret leading ? in config-file as an optional file
For example, `config-file = ?config.foo` will not report an error if
`config.foo` does not exist.
2024-09-15 09:47:44 -05:00
Mitchell Hashimoto
a9217bd9da config: "-e" implies quit after last window closed
Fixes #2220
2024-09-13 20:57:54 -07:00
Mitchell Hashimoto
779b721618 Merge pull request #2163 from jcollie/gtk-desktop-notification-fix
GTK: Fix clicking on desktop notifications
2024-09-13 20:52:18 -07:00
Mitchell Hashimoto
841e12a1eb config: make window-padding-color default to "background"
Unfortunately this is a failed experiment. The idea works in many
scenarios, but there are too many valid cases where it confuses people
or results in a very subjective experience. I'm going to revert this
back to "background" to act like other terminals, but the feature
remains available through config.
2024-09-13 20:51:15 -07:00
Mitchell Hashimoto
941adcdac8 apprt/gtk: rename the other underscore actions to match naming rules 2024-09-13 20:49:31 -07:00
Mitchell Hashimoto
9e73d865fb apprt/gtk: small comments 2024-09-13 20:45:39 -07:00
Jeffrey C. Ollie
5f759a19d1 GTK: Fix clicking on desktop notifications
Currently, clicking on a desktop notification will bring Ghostty
to the foreground, but it won't necessarily bring the right window
to the top and it won't switch tabs or change the focus on splits.

With this patch, clicking on a desktop notification will raise the
correct window, change to the correct tab, and focus on the correct
split that send the original desktop notification.
2024-09-13 13:37:38 -07:00
Mitchell Hashimoto
9548ae532d Merge pull request #2228 from Pangoraw/window-theme
apprt/gtk: add option to color header bars with theme colors
2024-09-13 10:09:44 -07:00
Mitchell Hashimoto
ddb3700609 config: copy 2024-09-13 10:08:48 -07: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
Jeffrey C. Ollie
12a791ddf2 gtk: prevent split separator from becoming transparent 2024-09-13 10:03:58 -05:00
Paul Berg
b935c7d46c apprt/gtk: remove adw_tab_page from tab 2024-09-13 15:32:17 +02:00
Paul Berg
d7f6f9999f config: remove note that window-new-tab-position is gtk only 2024-09-13 11:38:39 +02:00
Paul Berg
3dc4185d50 apprt/gtk: respect window-new-tab-position again 2024-09-13 11:37:23 +02:00
Paul
ac985937cd apprt/gtk: add theme variant in window-theme
this colours the header bar with the config colour.
2024-09-13 10:06:42 +02:00
Jeffrey C. Ollie
80c1fd436f adw: allow creating new tabs in a tab overview with no open tabs
Repro:
1) Start up Ghostty and create two windows.
2) On one window, open up the tab overview and close all of the tabs.
3) The window will not dissapear and should show that you have no open
   tabs because the 2nd Ghostty window is keeping Ghostty from quitting.
4) Clicking on the "New Tab" button has no effect.

Fix is to allow creating a new tab even though there is no action surface.
2024-09-12 21:04:06 -05:00
Mitchell Hashimoto
415f5cfe1b Merge pull request #2233 from tristan957/about
apprt/gtk: use AdwAboutDialog if available
2024-09-12 16:23:56 -07: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
Mitchell Hashimoto
3a60fd6550 apprt/gtk: use GtkWidget so there is a common ancestor 2024-09-12 15:54:07 -07:00
Tristan Partin
b7d26a3ac3 apprt/gtk: use AdwAboutDialog if available
Matches the libadwaita theme and UX.

Signed-off-by: Tristan Partin <tristan@partin.io>
2024-09-12 23:34:34 +01:00
Tristan Partin
a30fad7c59 apprt/gtk: use AdwHeaderBar if available
Signed-off-by: Tristan Partin <tristan@partin.io>
2024-09-12 20:29:50 +01:00
Mitchell Hashimoto
15924b285d Merge pull request #2221 from TheOnlyMrCat/gtk_opacity_2
Fix background-opacity for the GTK backend, again
2024-09-12 09:42:35 -07:00
Mitchell Hashimoto
a9a732ffce Merge pull request #2226 from ghostty-org/push-mtvnlywtrwsk
build: support building without .git directory
2024-09-12 09:40:15 -07:00
Mitchell Hashimoto
47b3e5617f build: support building without .git directory
Fixes #2223
2024-09-12 09:39:17 -07:00
Mitchell Hashimoto
4cacea3813 apprt/gtk: inline adwaita checks so comptime disables conditional paths
This fixes building without libadwaita or building with an older version
of libadwaita. This also updates the CI to test this.
2024-09-12 09:34:39 -07:00
Mitchell Hashimoto
21460e5ded apprt/gtk: hide header bar when window decorations are disabled
Fixes #2023
Fixes regression from #2051

#2051 introduced a regression where `window-decoration=false` had no
effect when libadwaita was in use. Further, the
`toggle_window_decorations` keybinding also had no effect whatsoever.

This commit fixes this and #2023 by explicitly hiding the header bar
when window decorations are disabled. We hide the header bar rather than
the full top bar because we still want the tab bar to show up with
window decorations disabled.
2024-09-11 21:05:12 -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
ff2ec11f8c config: update docs, caps 2024-09-11 12:06:40 -07:00
Paul
f0ca0e551e adw: show performance warning banner 2024-09-11 12:04:12 -07:00
Paul
fa81445701 adw: add option to choose toolbar style 2024-09-11 12:04:12 -07:00
Mitchell Hashimoto
050602a117 Merge pull request #2051 from Pangoraw/adw_tab_view
gtk: use Adwaita TabView when possible
2024-09-11 10:52:19 -07: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
2b5d436792 apprt/gtk: log the libadwaita version at startup if we use it 2024-09-11 10:27:35 -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
Mitchell Hashimoto
1ab850fa94 apprt/gtk: move adw enabling and version checks into shared file 2024-09-11 09:21:51 -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
05e7bf7634 gtk: add devel class to window in debug builds 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
Paul
0e22695ec4 gtk: use adwaita tab view when possible
add tab bar view
2024-09-11 15:35:22 +02:00
Mitchell Hashimoto
359272a5f5 macos: start Sparkle after loading config 2024-09-10 21:54:40 -07:00