Commit graph

729 commits

Author SHA1 Message Date
Dave Davenport
864a00b9fd Add option to dump filtered list to stdout.
uses format option and filter `-dump`.
2015-11-27 13:14:46 +01:00
Dave Davenport
2da1207b7d Fix issue #271 expand path. 2015-11-27 13:01:25 +01:00
Dave Davenport
e196df01fa Do not support ModMasks, breaks to much stuff, This fixes #286 2015-11-26 20:30:51 +01:00
Dave Davenport
3c411433b4 Big rename from Switcher to Mode internal, to match with user terminology 2015-11-25 09:26:38 +01:00
Dave Davenport
627643281d Fix ; in macro. 2015-11-24 22:53:40 +01:00
Dave Davenport
d1591273e7 Cleanups, rename and document. 2015-11-24 22:02:30 +01:00
Dave Davenport
00a555b685 Create more consistent ordering of arguments 2015-11-24 14:22:35 +01:00
Dave Davenport
6978b146f0 [Combi] only textual map, when not using glob/regex mode. 2015-11-24 14:14:55 +01:00
Dave Davenport
fa2bcd778c Fix for complete issue #273.
- Add complete handler.
2015-11-24 13:59:35 +01:00
Dave Davenport
cbba58914f Some cleanups and re-ordering of parameters to be consistent. 2015-11-23 22:15:27 +01:00
Dave Davenport
ad778b7dc1 Const making. 2015-11-23 22:15:27 +01:00
Qball Cow
84daf5fd6c Fix issue #285, clear memory on realloc 2015-11-23 17:11:12 +01:00
Qball Cow
596c92c814 Only add modmask if not numlock. 2015-11-23 14:10:07 +01:00
Dave Davenport
b974b10c96 [DRun] Skip entries that have NoDisplay set.
Closes issue #283
2015-11-23 09:47:29 +01:00
Dave Davenport
611c2c4302 Don't create collate, use normalized form to match. 2015-11-22 23:49:41 +01:00
Dave Davenport
65dd080154 Undo last commit, seems to be unneeded 2015-11-22 21:10:39 +01:00
Dave Davenport
5e05472619 Set LC_CTYPE and LC_COLLATE instead of LC_ALL 2015-11-22 20:55:48 +01:00
Dave Davenport
4510f65d5a textbox: advance cursor correctly for multi-char input
Thanks to eigengrau
fixes: #280
2015-11-22 20:41:45 +01:00
Sebastian Reuße
77617a97ec Initialize locale upon startup.
It seems that Xlib input contexts assume a C locale when the locale
hasn’t been initialized from the environment before the input context
is created. Inter alia, this will lead to Xlib reading the .XCompose
definition file as ISO-8859-1, which will result in mojibake when
composing characters in a UTF-8 environment (cf. #268).
2015-11-22 15:41:56 +01:00
Dave Davenport
5bdcd47dde consts and small ensurance (though should be correct to begin with) 2015-11-22 00:33:26 +01:00
Dave Davenport
8c9b72f34e Start at fixing Issue 273, this might break some things.
* Only use get_display_data for displaying. (Except the select complete (ctrl-space), this needs fixing).
 * Fix possible race condition in parallelization.
 * Fix small bug in case-sensitive handling. (beware for collision in keybinding)
 * Keep less lists around.
2015-11-21 23:59:59 +01:00
Dave Davenport
7dccd805ef Show error message when cannot bind key 2015-11-20 22:22:11 +01:00
Dave Davenport
66bd837c9e Second cleanup in the fix to #268 2015-11-20 22:00:37 +01:00
Dave Davenport
266ee5efb7 Hopefully fix for #268 2015-11-20 20:53:27 +01:00
Qball Cow
1bd231bc3d Fix issue #275: don't try to do move cursor when nothing is shown. 2015-11-20 11:43:22 +01:00
Dave Davenport
5f7694fc62 Issue #268, Filter out mode switch key. 2015-11-20 08:41:23 +01:00
Dave Davenport
ca5ea414c8 Issue #268 Repair combined key input 'e --> é 2015-11-20 08:19:48 +01:00
Dave Davenport
38d2bc717a handle failed regex better. 2015-11-17 16:25:42 +01:00
Dave Davenport
00c8439b57 Small fix 2015-11-17 16:21:30 +01:00
Dave Davenport
aeaceb154a Add experimental regex support 2015-11-17 16:10:14 +01:00
Dave Davenport
2b0aec52e0 Fix 2nd offset. #269 2015-11-16 21:07:49 +01:00
Dave Davenport
92248e6e13 (Hopefull) fix #259, color offset by 1 2015-11-16 21:06:03 +01:00
Dave Davenport
b70421e75b Remove duplicate code. 2015-11-16 08:17:30 +01:00
Dave Davenport
238a34162a Try to fix crasher on mixing glib free and free. 2015-11-15 13:12:43 +01:00
Dave Davenport
2eaffceada Fix printing. 2015-11-14 19:59:56 +01:00
Dave Davenport
64eb7851e1 Small cleanup 2015-11-14 19:52:15 +01:00
Dave Davenport
56e85d0f5a Cleanup. 2015-11-14 19:42:43 +01:00
Dave Davenport
b9d1fe6635 Small updates 2015-11-14 18:57:21 +01:00
Dave Davenport
12886ab0cb Add missing timing files. 2015-11-14 13:49:42 +01:00
Dave Davenport
80e873c8a3 Add threadpool support, add optional timings compile flag 2015-11-14 13:47:45 +01:00
Dave Davenport
45c8de9387 If threads is set to 0, try to autodetect number of threads. 2015-11-12 17:20:51 +01:00
Qball Cow
e6ca8acba9 Possible fix for issue #265. Check mask when accepting textbox input. 2015-11-12 15:42:00 +01:00
Qball Cow
311cedf87f Fix silly little bug. 2015-11-12 14:53:02 +01:00
Qball Cow
c7dcb4821a Use getdelim instead of custom fgets function. 2015-11-12 14:15:33 +01:00
Dave Davenport
880f8731be Fix crasher on small lists.. we need atleast 1 thread to do work! 2015-11-11 22:46:01 +01:00
Dave Davenport
0fe524d0cd Add threading support. 2015-11-12 00:18:43 +01:00
Dave Davenport
09ab44bf92 Fix #264 fall back to age ordered list if stacked list does not work 2015-11-10 23:52:52 +01:00
Dave Davenport
195dc0fb01 Cleanups. 2015-11-07 12:59:08 +01:00
Dave Davenport
c82d8832c9 Fix table layout. 2015-11-07 11:35:10 +01:00
Dave Davenport
53e9332603 Fix #260. 2015-11-07 11:20:25 +01:00
Qball Cow
aedd26aef4 Fix #258: Set fallback alternative color before trying to allocate it. 2015-11-04 12:03:59 +01:00
Dave Davenport
4c8404f87d Fix combi and drun and localization 2015-11-03 19:57:07 +01:00
Dave Davenport
80ac118655 Put things together, making desktop menu work 2015-11-03 17:34:02 +01:00
Dave Davenport
6f404ddc8e Initial import desktop file runner. 2015-11-03 08:31:38 +01:00
Dave Davenport
d01afc5303 Add xdg-terminal to list 2015-11-01 12:28:55 +01:00
Dave Davenport
b454791ccd Merge pull request #257 from klemens/no-parse-known-hosts
Add -no-parse-known-hosts option
2015-10-31 19:14:20 +01:00
Klemens Schölhorn
9cb0073ce8 Add -no-parse-known-hosts to disable parsing of ~/.ssh/known_hosts
For humans who like to keep the list of available servers clean. Also useful
if you use different names in ~/.ssh/config.

The previous default of always parsing known_hosts is not changed.
2015-10-31 18:35:37 +01:00
Dave Davenport
02b99e6f95 Fix: 256 Do not accept custom entry when not applicable.
Add test to reproducet .
2015-10-31 18:04:55 +01:00
Dave Davenport
f9e7bc0775 Possible fix for 256. Need test cases for these. 2015-10-31 17:31:24 +01:00
QC
cb9dd606aa Allow dpi to be set 2015-10-30 21:32:09 +01:00
Dave Davenport
46f9073f7e Fix #251 : Don't iterate over nil list. 2015-10-29 21:30:03 +01:00
QC
10292b08cb Fix: 250 Fixing message. 2015-10-26 20:13:15 +01:00
Qball Cow
7471a58325 Fix if active and urgent are both set. 2015-10-26 14:22:58 +01:00
QC
de1f7a11aa Merge remote-tracking branch 'origin/Transparency' 2015-10-21 20:42:40 +02:00
Rasmus Steinke
5962aa5302 unify help messages 2015-10-21 20:30:10 +02:00
Dave Davenport
bc2b532a51 Add dmenu options to -h 2015-10-21 18:58:01 +02:00
Dave Davenport
d21ba860f0 Add main application options to -h 2015-10-21 09:42:55 +02:00
Dave Davenport
bc7a89c646 Print comment with each option. 2015-10-21 09:20:07 +02:00
Qball Cow
b4880b3601 Small tweak. 2015-10-20 18:58:03 +02:00
Qball Cow
f52e73a4f2 Only store the monitor we are currently displayed on 2015-10-20 18:51:29 +02:00
Qball Cow
a7c7cf8159 Add fake transparency 2015-10-20 18:41:45 +02:00
Dave Davenport
64cb4c781c Fix some compiler warnings 2015-10-19 09:23:06 +02:00
QC
1b425c7bd0 Fix crash on deleting entries in ssh/run.
Fix bang for custom run.
2015-10-18 22:12:06 +02:00
QC
683632c36c Some cleanups 2015-10-18 19:02:19 +02:00
QC
73fd87f820 Add mesg about fullscreen and monitor setup 2015-10-18 13:45:15 +02:00
QC
93b6b83fb9 Try todo some validation of monitor size/padding in config sanity check. 2015-10-18 13:40:39 +02:00
QC
0818fbd68b Add fullscreen mode and fix some redrawing issues. 2015-10-16 20:51:37 +02:00
Dave Davenport
291d1ed16c Update rofi -h output 2015-10-16 08:42:01 +02:00
QC
44b9854594 Add comment. 2015-10-15 22:44:35 +02:00
QC
fdc86399cf Revert "Remove levenshtein"
Adding help list.

This reverts commit 77cdc8d7c4.
2015-10-15 22:33:44 +02:00
Dave Davenport
4975704a05 Fix #244 Do not catch sigchld, let glib handle this internally
- TODO fix man page viewing.
2015-10-12 08:12:25 +02:00
QC
56e023dcee Remove unneeded check. 2015-10-11 14:13:08 +02:00
Dave Davenport
cc6bf27ccb Merge branch 'master' of github:DaveDavenport/rofi 2015-10-11 13:43:32 +02:00
Dave Davenport
c9746e8543 Merge remote-tracking branch 'faf/fast-ascii-filtering' 2015-10-11 13:42:56 +02:00
QC
2898eeda88 Cache colors. 2015-10-10 14:15:27 +02:00
QC
d5549db384 Strip color, should fix #233 2015-10-10 13:43:28 +02:00
QC
b0ceccb93e Use cairo for all drawing, also borders 2015-10-10 13:03:11 +02:00
Dave Davenport
01aa2e32cc When element is to high, don't y center. 2015-10-05 18:22:01 +02:00
Tom Hinton
a53061b890 Merge remote-tracking branch 'upstream/master' into fast-ascii-filtering
Conflicts:
	source/dialogs/dmenu.c
	source/helper.c
	source/rofi.c
2015-10-05 10:44:11 +01:00
QC
77cdc8d7c4 Remove levenshtein 2015-10-04 20:14:08 +02:00
QC
9a39ebb3e9 Fix typo 2015-10-04 17:02:54 +02:00
Dave Davenport
6b039ac524 Add tokenize option and append * to glob. 2015-10-04 16:37:07 +02:00
QC
1369c162fe Remove debug 2015-10-02 22:24:49 +02:00
QC
5de38cd755 Add glob version for testing. 2015-10-02 20:39:57 +02:00
Tom Hinton
c2d8cb1f45 Move ascii testing gizmos to macros at the top.
Still not sure about best way to do this.
2015-10-02 09:58:56 +01:00
Tom Hinton
3ba2da9cae Fix mistakes from copy paste 2015-10-01 18:18:01 +01:00
Tom Hinton
d1a5b0d362 whoops, rogue print statement 2015-10-01 13:46:50 +01:00
Tom Hinton
0a953a03b4 Make fuzzy matching fast and unicode-happy 2015-10-01 13:45:23 +01:00
Tom Hinton
af6a4b83eb Make normal filtering of plain ASCII lines faster
This patch adds a field lines_not_ascii to the MenuState structure. The
nth entry is 0 unless the nth member of MenuState.lines has a non-ascii
codepoint in it.

All comparison functions (menu_match_cb type) take an additional
argument to tell them if the thing they are matching is not_ascii. They
can use this to determine whether to collate and case-fold the
input (for non-ascii strings), or whether to use strstr/strcasestr (for
ascii strings).

The change is not currently implemented for flex matching, due to my
laziness. However, it should be a simple enough matter to add.

For my large input of 400,000 lines, this reduces typical filtering time
to about ten microseconds from about 2 seconds.
2015-10-01 12:16:41 +01:00
Tom Hinton
574bf2da82 Make dmenu reading very marginally faster
A slight reduction in use of realloc and avoidance of 3 or 4 strlens for
a string we know the length of
2015-10-01 11:41:44 +01:00