bookloupe/counters.h
author ali <ali@juiblex.co.uk>
Tue Sep 24 22:28:02 2013 +0100 (2013-09-24)
changeset 111 f805130deb6f
parent 103 adc06e9e8470
permissions -rw-r--r--
Fix bug #11: Test for balanced "slanted" UTF-8 quotation marks 8220/8221
     1 #ifndef COUNTERS_H
     2 #define COUNTERS_H
     3 
     4 #include <glib.h>
     5 
     6 /* Special counters live in the private use area */
     7 enum {
     8     COUNTER_ILLUSTRATION=0xE000,
     9     NO_SPECIAL_COUNTERS
    10 };
    11 
    12 struct counters {
    13     GTree *matching;
    14     int c_unders;
    15 };
    16 
    17 void increment_matching(struct counters *counters,gunichar ch,gboolean open);
    18 int matching_count(const struct counters *counters,gunichar ch,gboolean open);
    19 int matching_difference(const struct counters *counters,gunichar ch);
    20 void counters_reset(struct counters *counters);
    21 void counters_destroy(struct counters *counters);
    22 
    23 #endif /* COUNTERS_H */