Linux-PowerToys icon indicating copy to clipboard operation
Linux-PowerToys copied to clipboard

Add Run utility

Open J-Marte opened this issue 1 year ago • 2 comments

Hello,

I have wrote some Code for a rough implementation of the run-utility over at my Fork in the feature/run branch. It is a separate Flutter-Application so that it can operate independently. I would like to integrate it into this Project. There are still a lot of things to do before it is stable and release ready (wrap into Gnome Extension, Settings, DBus interface naming, documentation, ...).

J-Marte avatar Jul 03 '24 20:07 J-Marte

Hey, great work! How does your implementation work? I'm curious to know!

domferr avatar Jul 14 '24 18:07 domferr

The Implementation will be split into two parts, the flutter application and gnome-extension.

flutter application

The flutter application handles the searching and displaying of the search results.

Summoning

The app listens on a D-Bus interface for the toggleVisibility method call and toggles the visibility via the window_size package

Plugins

When the user enters a search-text each plugin (if no activation Prefix is given) starts generating search results based on it's own cached search entries. The UI uses this search results to display the them in the correct order.

The plugins also implement the actions. For example to open a VScode-Workspace or the Git-repository in a terminal.

Search engine

The default search engine searches in the title and subtitle for all word given in the search text and generates based on the amount of occurrences and length of the search text a rating and highlight-sections.

UI

The ui handles the keyboard inputs, such as arrow movements/tabs to navigate through the application without mose and execution of the actions provided by the search-results.

Gnome Extensions (not implemented)

The Gnome Extension will handle the things which the App can not handle such as:

  • summoning with global key press
  • positioning of the window (i hope this can be done here, because based on my research it is not possible under wayland to reliable set the position)
  • remove is ready notification when visibility is changed

J-Marte avatar Jul 15 '24 16:07 J-Marte