Commit Graph

251 Commits

Author SHA1 Message Date
Přemysl Eric Janouch bc939712cb
sdtui: lay the groundwork for formatted entries 2021-10-10 06:13:49 +02:00
Přemysl Eric Janouch 6f7fbbb438
sdtui: keep the per-ViewEntry GPtrArrays 2021-10-10 06:13:48 +02:00
Přemysl Eric Janouch 39ff4069c0
tabfile: fix file format version downgrade 2021-10-10 01:57:51 +02:00
Přemysl Eric Janouch fbfd8c7d02
tabfile: add support for writing Pango markup
Enabling this option will ensure the field would parse.
2021-10-10 01:52:15 +02:00
Přemysl Eric Janouch 8b9c5e0460
Add the Czech WordNet snapshot to dicts 2021-10-10 00:45:38 +02:00
Přemysl Eric Janouch 973d1d27ea
Improve documentation 2021-10-07 20:11:36 +02:00
Přemysl Eric Janouch 55d0f53f7a
Abandon the idea of sts for slovnik-cizich-slov
We'd need something like inlining the type sequence within the data,
which doesn't seem particularly elegant.
2021-10-07 17:24:24 +02:00
Přemysl Eric Janouch 20fcf2a0c7
tabfile: make it possible to set metadata
And some related clean-up.
2021-10-07 16:28:44 +02:00
Přemysl Eric Janouch ed8b1bcdad
Add sample dictionary downloaders/builders 2021-10-07 14:06:57 +02:00
Přemysl Eric Janouch 3881725904
tabfile: remember to check UTF-8, glibize 2021-10-06 22:11:21 +02:00
Přemysl Eric Janouch 6c364dc997
Add an implementation of tabfile
The original one is a horrible thing.  Now we're self-reliant.
2021-10-06 22:04:55 +02:00
Přemysl Eric Janouch 690402f2e1
Unbreak stardict_dict_get_synonyms()
Untested, but certainly broken six ways to Sunday before.
2021-10-06 20:14:49 +02:00
Přemysl Eric Janouch 03f2123447
GLib-related improvements
Now all error messages produced by tools should be in the right
encoding, even if the system isn't in UTF-8.
2021-10-06 16:11:55 +02:00
Přemysl Eric Janouch 3c87b95c31
Make Tab put the current definition into search
Moving some X11-only code out.
2021-10-06 13:44:54 +02:00
Přemysl Eric Janouch fffa2906d8
Update README
It turns out sdtui works in Sway out of the box (essentially).
2021-07-24 23:46:28 +02:00
Přemysl Eric Janouch 4245dc35df
Update README, add a screenshot
I've given up on the idea of a "proper" TUI framework.

I've also learnt that Wayland isn't a completely dead end.
2021-07-23 20:46:14 +02:00
Přemysl Eric Janouch 87f90f6420
Update .gitignore 2021-07-07 00:02:00 +02:00
Přemysl Eric Janouch 2b5eb86a9f
sdtui: enable styling of defocused selected rows
The defaults are unaffected, the row is always reverse, like it used to.

Having the deselected row just be underlined seems sensible.

It isn't currently possible to change /just/ the foreground or
the background colour of the selection, due to how ncurses works
with colours.

Bumped termo to enable requesting the appropriate events.
2021-07-03 11:44:01 +02:00
Přemysl Eric Janouch 85ca0c5857
sdtui: normalize whitespace in clipboard input 2021-07-03 11:36:46 +02:00
Přemysl Eric Janouch bb4e732a25
Bump termo 2020-10-29 15:57:14 +01:00
Přemysl Eric Janouch 911749475e
CMakeLists.txt: omit end{if,foreach} expressions
Their usefulness was almost negative.
2020-10-29 15:43:05 +01:00
Přemysl Eric Janouch f15fc0f00a
Cleanup 2020-10-26 17:57:24 +01:00
Přemysl Eric Janouch d2fa9f3151
Convert the manpage to AsciiDoc
Writing DocBook XML by hand is an awful experience and the tools aren't
much better.  Asciidoctor does it well.  There's no need to worry about
semantics, man(1) just needs to be able to show something at all.

This project's manpage is sadly almost useless right now.
2020-10-26 17:06:13 +01:00
Přemysl Eric Janouch d7f502a731
Bump termo 2020-10-26 15:16:47 +01:00
Přemysl Eric Janouch 7743e21bca
Bump minimum CMake version to 3.0
A nice, round number.  This allows us to remove some boilerplate.
2020-10-26 15:16:46 +01:00
Přemysl Eric Janouch 504f1ce2f5
Bump termo 2020-09-14 18:07:12 +02:00
Přemysl Eric Janouch e47667b28a
sdgtk: don't follow our own selection
When the main window is focused, we are probably the owner of it.
2020-09-14 02:02:38 +02:00
Přemysl Eric Janouch aa19848499
Add an experimental GTK+ UI
It has a potential to stay simpler than the TUI,
while having a wider feature set.

Not building this toy by default, it needs some time investment.
2020-09-08 05:02:14 +02:00
Přemysl Eric Janouch 588b6ef8bb
Fix a segfault when search goes past the end
Removing a preprocessor macro in favor of a normal function.
2020-09-08 05:01:31 +02:00
Přemysl Eric Janouch fda956093c
Update copyright years within the program 2020-09-07 19:05:16 +02:00
Přemysl Eric Janouch 74f2bcae34
Get rid of one CMake dev warning 2020-09-07 18:39:59 +02:00
Přemysl Eric Janouch 695f71d946
tools: clean up error message printing 2020-09-04 00:13:34 +02:00
Přemysl Eric Janouch 8d19acd91a
Add a tool to transform dictionaries 2020-09-04 00:13:34 +02:00
Přemysl Eric Janouch dd2bd04a07
Fix a typo 2020-09-03 23:15:59 +02:00
Přemysl Eric Janouch bbe22712fe
Enable switching among more than 10 dictionaries
Ctrl + PageUp/PageDown/Left/Right now change the active tab.
2020-09-02 16:29:59 +02:00
Přemysl Eric Janouch 37bf8ee648
Name change 2020-09-02 16:27:45 +02:00
Přemysl Eric Janouch 675139edb0
Disable GLib deprecation warnings
Not very useful.
2020-04-15 07:07:47 +02:00
Přemysl Eric Janouch 1289c98ca8
Bump to GLib 2.38 because of deprecation warnings 2020-04-15 07:00:36 +02:00
Přemysl Eric Janouch fcc0c3ef2d
Fix an unimportant memory leak 2018-09-23 11:45:23 +02:00
Přemysl Eric Janouch 2efaed1a56
Implement the INCR ICCCM selection mechanism
xcb_get_property is now also called with a length that is a multiple
of four so that we advance the offset properly.

Some cleanup.

Selection code should work pretty well by now.  The amount of code
supporting it has more than doubled since GTK+.
2018-09-23 11:45:13 +02:00
Přemysl Eric Janouch 86417d512b
Re-shuffle code, no functional changes 2018-09-23 06:38:03 +02:00
Přemysl Eric Janouch 942bda7db4
Use XCB and SelectSelectionInput instead of GTK+
As it happens, there is no real need to constantly poll for changes,
since XFixes can inform us of updates as they happen.

With GTK+ gone we've got dependencies and error handling under control.
XCB is a truly awful thing to learn, though.

Our method will never work on Wayland or Windows, so we don't miss out
on anything by abandoning the huge toolkit.
2018-09-23 06:38:03 +02:00
Přemysl Eric Janouch b0d3b2dcb5
Strip whitespace from clipboard contents 2018-06-30 13:23:30 +02:00
Přemysl Eric Janouch 4b191cce3d
Remove .travis.yml
We don't depend on any proprietary services no longer.  I'll have to
make my own replacements with blackjack and hookers.  Until then,
the file stays in the commit log as an example.
2018-06-24 05:24:03 +02:00
Přemysl Eric Janouch f09628dabd
Update README 2018-06-24 05:23:48 +02:00
Přemysl Eric Janouch e5faed57c2
Relicense to 0BSD, update mail address
I've come to the conclusion that copyright mostly just stands in the way
of software development.  In my jurisdiction I cannot give up my own
copyright and 0BSD seems to be the closest thing to public domain.

The updated mail address, also used in my author/committer lines,
is shorter and looks nicer.  People rarely interact anyway.
2018-06-24 05:23:31 +02:00
Přemysl Eric Janouch 8dc0176c41
CMakeLists.txt: fix variable name 2018-06-24 05:22:51 +02:00
Přemysl Eric Janouch a6c319876e
Bump termo 2018-06-24 05:20:17 +02:00
Přemysl Eric Janouch 80306c5779
Skip combining marks in the editor
For slightly more correct Unicode handling.
2017-06-27 20:03:38 +02:00
Přemysl Eric Janouch b0e5055f42
Bump termo 2017-06-20 06:37:39 +02:00