Skip to content

Commit

Permalink
Resolve some gtk errors/warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
dynobo committed Feb 4, 2024
1 parent e539efc commit c0c7e5e
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 12 deletions.
14 changes: 10 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
# Changelog

## v0.4.0 (Upcoming)

- Breaking: Switch from yaml to toml format for shortcuts
- Add filtering
## v0.4.0 (2024-02-04)

- Breaking changes in config files:
- Switch from yaml to toml format for shortcuts (you can use
[`yq`](https://mikefarah.gitbook.io/yq/) to convert yaml to toml)
- The key `hints` is renamed to `section`
- Dropping binary builds! Please install via `pipx install keyhint` instead.
- Add filter for shortcuts or section.
- Add possibility to hide whole cheatsheets via `hidden = true` in config files.
- Add fullscreen mode as default (toggle via `F11`)

## v0.3.0 (2023-02-12)

Expand Down
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,15 @@ window. (GTK 4.6+ required!)_**
## Prerequisites

- Python 3.11+
- GTK 4.6+ (since Ubuntu 22.04)
- `libcairo2-dev libgirepository1.0-dev` (Package name on Ubuntu/Debian)
- GTK 4.6+ (shipped since Ubuntu 22.04) + dev packages:
```sh
sudo apt-get install \
libgirepository1.0-dev \
libcairo2-dev \
python3-gi \
gobject-introspection \
libgtk-4-dev
```

## Installation

Expand Down
5 changes: 0 additions & 5 deletions keyhint/resources/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,6 @@
box-shadow: inset 0 -3px @shadow_color;
}

.dim-label {
margin-left: -3px;
margin-right: -3px;
}

.bindings-section header label {
color: @accent_color;
margin-top: 26px;
Expand Down
Binary file modified keyhint/resources/vscode.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 5 additions & 1 deletion keyhint/window.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def __init__(self, cli_args: dict) -> None:
if self.cli_args.get("orientation", "vertical") == "horizontal":
self.sheet_container_box.set_orientation(1)

if self.cli_args.get("no-fullscreen", False):
if not self.cli_args.get("no-fullscreen", False):
self.fullscreen()

# Make sure the window is focused
Expand Down Expand Up @@ -131,6 +131,10 @@ def init_search_entry(self) -> None:
evk = Gtk.EventControllerKey()
evk.connect("key-pressed", self.on_search_entry_key_pressed)
self.search_entry.add_controller(evk)

# Reusing the same evk leads to critical assertion error
evk = Gtk.EventControllerKey()
evk.connect("key-pressed", self.on_search_entry_key_pressed)
self.search_entry_fullscreen.add_controller(evk)

@Gtk.Template.Callback()
Expand Down

0 comments on commit c0c7e5e

Please sign in to comment.