int url_get_amount(void);
void url_purge(void);
void url_dump(void);
+int url_count_inline(const char *line);
#endif // !defined( URL_H )
int url_get_amount(void) {
return index_max;
}
+
+int url_count_inline(const char *line) {
+ int count = 0;
+ const char* i = line;
+
+ for (; *i; i++) {
+ if (*i == '\\') {
+ i++;
+ } else if ( *i == '[' && *(i+1) != ']') {
+ while (*i && *i != ']') i++;
+ i++;
+ if (*i == '(' && strchr(i, ')')) {
+ count ++;
+ i = strchr(i, ')') + 1;
+ }
+ }
+ }
+
+ return count;
+}
line = slide->line;
while(line) {
+
+ if (line && line->text && line->text->text)
+ lc += url_count_inline(line->text->text);
+
if(line->length > COLS) {
i = line->length;
offset = 0;