Logo Search packages:      
Sourcecode: pan version File versions  Download package

void Numbers::mark_str ( const StringView str,
bool  add = true 

Mark numbers from a text string in to_str() and from_str() fromat.

numbersascii-formatted string of numbers to mark.
addtrue if we're adding the numbers, false if removing

Definition at line 194 of file numbers.cc.

References mark_range().

   StringView phigh, p(str);

   while (p.pop_token (phigh, ','))
      StringView plow;
      phigh.pop_token (plow, '-');
      plow.trim ();
      phigh.trim ();
      const unsigned long low (plow.empty() ? 0 : strtoul (plow.str, NULL, 10));
      const unsigned long high (phigh.empty() ? low : strtoul (phigh.str, NULL, 10));
      mark_range (low, high, add);

Here is the call graph for this function:

Generated by  Doxygen 1.6.0   Back to index