From: Michael D. Lowis Date: Wed, 19 Sep 2018 00:55:57 +0000 (-0400) Subject: fixed bug in handling tag arguments X-Git-Url: https://git.mdlowis.com/?a=commitdiff_plain;h=6f9911e52c79fb4e57c795ce8cbc2dfca73b2a20;p=projs%2Ftide.git fixed bug in handling tag arguments --- diff --git a/lib/config.c b/lib/config.c index 1ce32cf..711f6ea 100644 --- a/lib/config.c +++ b/lib/config.c @@ -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 51e1f37..9dfbf3a 100644 --- 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); }