summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2021-01-06 17:36:07 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2021-01-06 17:36:07 -0500
commit132dcb648981050990e34a44925e6b54d0dc008c (patch)
tree7a41a97308b1921c62d2f5afd12c7cf475f14247 /util.c
parent9e055b2e25455fc4fa0376495ccc9335059f3131 (diff)
more open menu, border thickness setting, fixed small text clipping issue
Diffstat (limited to 'util.c')
-rw-r--r--util.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/util.c b/util.c
index aa4a737..5bde9b6 100644
--- a/util.c
+++ b/util.c
@@ -146,3 +146,12 @@ static bool str_satisfies(char const *s, int (*predicate)(int)) {
return true;
}
+// function to be passed into qsort for case insensitive sorting
+static int str_qsort_case_insensitive_cmp(const void *av, const void *bv) {
+ char const *const *a = av, *const *b = bv;
+#if _WIN32
+ return _stricmp(*a, *b);
+#else
+ return strcasecmp(*a, *b);
+#endif
+}