| 43 | } |
| 44 | |
| 45 | int ValueFor(const std::string &s) const { |
| 46 | std::map<std::string, int>::const_iterator it = wordToStyle.find(s); |
| 47 | if (it != wordToStyle.end()) |
| 48 | return it->second; |
| 49 | else |
| 50 | return -1; |
| 51 | } |
| 52 | |
| 53 | bool IncludesStyle(int style) const { |
| 54 | return (style >= firstStyle) && (style < (firstStyle + lenStyles)); |