"Fossies" - the Fresh Open Source Software Archive

Member "scribus-1.5.6.1/scribus/text/scworditerator.h" (14 Nov 2020, 969 Bytes) of package /linux/misc/scribus-1.5.6.1.tar.xz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "scworditerator.h" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 1.5.6_vs_1.5.6.1.

    1 /*
    2  For general Scribus (>=1.3.2) copyright and licensing information please refer
    3  to the COPYING file provided with the program. Following this notice may exist
    4  a copyright and/or license notice that predates the release of Scribus 1.3.2
    5  for which a new license (GPL+exception) is in place.
    6  */
    7 
    8 #ifndef SCWORDITERATOR_H
    9 #define SCWORDITERATOR_H
   10 
   11 #include <QString>
   12 #include <unicode/uversion.h>
   13 
   14 #include "scribusapi.h"
   15 #include "storytext.h"
   16 
   17 U_NAMESPACE_BEGIN
   18 class BreakIterator;
   19 class UnicodeString;
   20 U_NAMESPACE_END
   21 
   22 class SCRIBUS_API ScWordIterator
   23 {
   24 public:
   25     ScWordIterator(StoryText& story);
   26     ~ScWordIterator();
   27     
   28     int firstWord();
   29     int nextWord(int pos);
   30     int prevWord(int pos);
   31     int endOfWord(int pos);
   32 
   33     QString word(int pos);
   34     
   35 private:
   36     icu::UnicodeString* m_unicodeString { nullptr };
   37     icu::BreakIterator* m_wordIterator { nullptr };
   38     StoryText& m_story;
   39     
   40     icu::BreakIterator* getWordIterator();
   41 };
   42 
   43 #endif