/[LeafOK_CVS]/lbbs/src/lml.c
ViewVC logotype

Diff of /lbbs/src/lml.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.45 by sysadm, Thu Nov 6 13:20:24 2025 UTC Revision 1.46 by sysadm, Mon Nov 10 11:54:30 2025 UTC
# Line 209  int lml_render(const char *str_in, char Line 209  int lml_render(const char *str_in, char
209          int fb_quote_level = 0;          int fb_quote_level = 0;
210          int tag_name_found;          int tag_name_found;
211          int line_width = 0;          int line_width = 0;
212            char tab_spaces[TAB_SIZE + 1];
213            int tab_width = 0;
214    
215          clock_begin = clock();          clock_begin = clock();
216    
# Line 323  int lml_render(const char *str_in, char Line 325  int lml_render(const char *str_in, char
325                  {                  {
326                          continue; // Skip special characters                          continue; // Skip special characters
327                  }                  }
328                    else if (str_in[i] == '\t')
329                    {
330                            tab_width = TAB_SIZE - (line_width % TAB_SIZE);
331                            if (line_width + tab_width > width)
332                            {
333                                    CHECK_AND_APPEND_OUTPUT(str_out, buf_len, j, "\n", 1, line_width);
334                                    new_line = 1;
335                                    line_width = 0;
336                                    // skip current Tab
337                                    continue;
338                            }
339    
340                            for (k = 0; k < tab_width; k++)
341                            {
342                                    tab_spaces[k] = ' ';
343                            }
344                            tab_spaces[tab_width] = '\0';
345                            CHECK_AND_APPEND_OUTPUT(str_out, buf_len, j, tab_spaces, tab_width, line_width);
346                            continue;
347                    }
348    
349                  if (!lml_tag_disabled && str_in[i] == '[')                  if (!lml_tag_disabled && str_in[i] == '[')
350                  {                  {


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1