]> git.mdlowis.com Git - projs/tide.git/commitdiff
fixed bug in handling tag arguments
authorMichael D. Lowis <mike@mdlowis.com>
Wed, 19 Sep 2018 00:55:57 +0000 (20:55 -0400)
committerMichael D. Lowis <mike@mdlowis.com>
Wed, 19 Sep 2018 00:55:57 +0000 (20:55 -0400)
lib/config.c
tide.c

index 1ce32cfd231884082b72efde434023711f0562dc..711f6ea4a2e2186fc7cbbd8c528e63a1864c166a 100644 (file)
@@ -7,7 +7,11 @@
 char* TagString = "Del Put Undo Redo | Font Tabs | Find ";
 char* Fonts[2] = {
     "Verdana:size=11",
+#ifdef __MACH__
+    "Monaco:size=11"
+#else
     "Liberation Mono:size=11"
+#endif
 };
 
 int /* Integer config options */
diff --git a/tide.c b/tide.c
index 51e1f378615f3e44ee821c07cfba32cbb092dd05..9dfbf3a958de547f4560e619f293a6297b531830 100644 (file)
--- a/tide.c
+++ b/tide.c
@@ -44,10 +44,10 @@ static Tag* tag_lookup(char* cmd) {
 
 static void tag_exec(Tag* tag, char* arg) {
     /* if we didnt get an arg, find one in the selection */
-    if (!arg || *arg) arg = view_getstr(win_view(TAGS));
-    if (!arg || *arg) arg = view_getstr(win_view(EDIT));
+    if (!arg || !*arg) arg = view_getstr(win_view(TAGS));
+    if (!arg || !*arg) arg = view_getstr(win_view(EDIT));
     /* execute the tag handler */
-    tag->action(arg || *arg ? NULL : arg);
+    tag->action(!arg || !*arg ? NULL : arg);
     free(arg);
 }