Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
This was done by breaking the selected result into three parts, and
rendering each separately. A side-effect is that ligatures split when a
match ends inside them, but I think that's the correct behaviour (rather
than highlighting the whole ligature).
There may be issues with some non-latin languages that make much more
extensive use of ligatures / combining characters, however.
|
|
|
|
|
|
This adds some extra padding in the selection background, rather than
tightly wrapping the selection text.
|
|
This fixes some slanted fonts being cut off if they extend back towards
the prompt too far.
|
|
|
|
Previously, tofi-drun would print the filename of the selected
.desktop file to stdout. This could then be passed to
`xargs swaymsg exec gio launch` to be executed.
The problem is that this ends up defeating the purpose of passing the
command to swaymsg exec, and the workspace the command was selected on
may not be the one that it starts up on, if for example it takes a long
time and the user switches workspaces in the meantime.
The solution is to instead print the Exec= line from the .desktop file,
and pass that directly to `xargs swaymsg exec --` for execution.
To avoid too much breaking of configs for the few people who use tofi
currently, this commit adds a new option, --drun-print-exec, to enable
the fixed behaviour. A future release will change this to be the
default, however.
|
|
|
|
There's starting to be a fair amount of duplicated code between the drun
and normal run modes. At some point in the future, it's likely to be
worth combining them, such that there's only a single
`struct search_item` or similar, and just handle the different modes at
the start and end of execution.
|
|
Tofi will now try to autodetect how many results can be drawn if
--num-results=0 is specified, which is now the default.
|
|
|
|
This should fix tofi not grabbing keyboard focus on River.
|
|
|
|
This is a pretty simple implementation, but it should work for most
use cases. Notably, generic application names aren't used (though that
could be added without too much hassle), and neither are keywords (that
would be more difficult).
|
|
Probably a good idea to allow more than 128 runs of a program.
|
|
Search results will now be sorted by history first, then by the position
of the match, such that a match at the start of a result will appear
before a match later in the result.
|
|
This was caused by some unneeded leftover logic that resulted in
surface_draw being called without a corresponding entry_update.
|
|
|
|
|
|
Tofi should now appear on whatever the compositor's default output is
(usually the focused one), unless --output has been given.
|
|
|
|
|
|
The --output option can be passed to select a specific output to appear
on. Which output is chosen otherwise is currently random, as I don't
know yet how to determine which one the user's currently on.
|
|
|
|
|
|
Also change --font-name option to just --font.
|
|
|
|
|
|
|
|
Also improve text on non-hidpi screens.
|
|
This improves start-up performance for large windows.
|
|
|
|
Implement horizontal mode for Pango, and add min-input-width option.
|
|
|
|
Currently the clipping region is still a plain rectangle bounded by the
outer rounded rectangle. A rounded rectangle clip would be nice, but
unfortunately Cairo leaves antialiasing artifacts if we do this.
|
|
|
|
Tofi now uses Harfbuzz if a file is passed to --font-name, and Pango
otherwise.
|
|
The scale factor is now only used to scale font sizes, not all Cairo
drawing operations. This makes pixel-sized options correct.
|
|
Invoking 'tofi' now acts like dmenu, expecting newline-separated options
on stdin.
Also fix history file handling and add an option to disable it.
|
|
|
|
|
|
|
|
|
|
Single letter style arguments have been removed.
|
|
There are too many really to use single-character args, so the next step
should be a config file.
|
|
A list of commands is now stored in $XDG_CACHE_HOME/.cache/tofi-compgen,
and regenerated as necessary.
|
|
- Split the compgen and history sorting parts of compgen(), for future
dmenu-like work.
- Add a separate tofi-compgen executable.
- Remove harfbuzz-glib usage, as we shouldn't be doing any complicated
unicode stuff.
|