regolith-linux / ilia

A GTK-based Desktop Executor
Apache License 2.0
85 stars 11 forks source link

Festure Request: add calculator function #65

Open nesono opened 1 year ago

nesono commented 1 year ago

As an ilia user, I would love to be able to do some small calculations with ilia.

One way to add the feature could be to switch on evaluation when the user starts the query with an equal sign (like Alfred does).

I'd be happy to spend some cycles myself, but I have no real experience with Vala and GTK+ development. So if you give me some pointers m, I might kick something off myself...

kgilmer commented 1 year ago

Hi @nesono , ilia has a plugin style architecture that would make it pretty easy to add a "calculator" tab that could be loaded. I have found the language to be similar to the traditional OO languages C# and Java and did not have much trouble picking it up. For me, most of the difficulty is in understanding Gtk docs. In any case , if you'd like to get started, here is some example code: https://wiki.gnome.org/Projects/Vala/Examples

You could create a new directory from here that provides a class that implements DialogPage.

kgilmer commented 1 year ago

The textlist page is probably the simplest to see how things work and get started.