Référence de la classe KoFindReplace

#include <KoSearchDia.h>

Graphe de collaboration de KoFindReplace:

[légende]
Liste de tous les membres

Fonctions membres publiques

 KoFindReplace (QWidget *parent, KoSearchDia *dialog, const Q3ValueList< KoTextObject * > &lstObject, KoTextView *textView)
 KoFindReplace (QWidget *parent, KoReplaceDia *dialog, const Q3ValueList< KoTextObject * > &lstObject, KoTextView *textView)
 ~KoFindReplace ()
KoTextParagcurrentParag ()
bool isReplace () const
bool shouldRestart ()
bool findNext ()
bool findPrevious ()
void setActiveWindow ()
void emitUndoRedo ()
virtual void emitNewCommand (KCommand *)=0
virtual void highlightPortion (KoTextParag *parag, int index, int length, KoTextDocument *textdoc, KDialog *dialog)=0
bool validateMatch (const QString &text, int index, int matchedlength)

Connecteurs protégés

void slotFindNext ()
void optionsChanged ()
void dialogClosed ()
void highlight (const QString &text, int matchingIndex, int matchingLength)
void replace (const QString &text, int replacementIndex, int replacedLength, int searchLength)
void slotCurrentParagraphModified (int, int, int)

Fonctions membres protégées

void replaceWithAttribut (KoTextCursor *cursor, int index)
KMacroCommand * macroCommand ()
long options () const
void setOptions (long opt)
void removeHighlight ()
bool needData () const
void setData (const QString &data, int startPos=-1)

Fonctions membres privées

void connectFind (KFind *find)

Attributs privés

KoTextFindm_find
KoTextReplacem_replace
KoSearchContext m_searchContext
KoSearchContext m_replaceContext
bool m_searchContextEnabled
bool m_doCounting
bool m_bInit
bool m_currentParagraphModified
KMacroCommand * m_macroCmd
int m_offset
int m_matchingIndex
KoTextIterator m_textIterator
KoTextObjectm_lastTextObjectHighlighted

Description détaillée

This class implements the 'find' functionality ( the "search next, prompt" loop ) and the 'replace' functionality. Same class, to allow centralizing the findNext() code.

Définition à la ligne 205 du fichier KoSearchDia.h.


Documentation des contructeurs et destructeur

KoFindReplace::KoFindReplace ( QWidget *  parent,
KoSearchDia dialog,
const Q3ValueList< KoTextObject * > &  lstObject,
KoTextView textView 
)

Définition à la ligne 152 du fichier KoSearchDia.cpp.

Références connectFind(), et m_find.

Voici le graphe d'appel pour cette fonction :

KoFindReplace::KoFindReplace ( QWidget *  parent,
KoReplaceDia dialog,
const Q3ValueList< KoTextObject * > &  lstObject,
KoTextView textView 
)

Définition à la ligne 167 du fichier KoSearchDia.cpp.

Références connectFind(), m_replace, et replace().

Voici le graphe d'appel pour cette fonction :

KoFindReplace::~KoFindReplace (  ) 

Définition à la ligne 206 du fichier KoSearchDia.cpp.

Références m_find, m_replace, et removeHighlight().

Voici le graphe d'appel pour cette fonction :


Documentation des fonctions membres

KoTextParag* KoFindReplace::currentParag (  )  [inline]

Définition à la ligne 213 du fichier KoSearchDia.h.

Référencé par validateMatch().

Voici le graphe d'appel pour cette fonction :

bool KoFindReplace::isReplace (  )  const [inline]

Définition à la ligne 217 du fichier KoSearchDia.h.

bool KoFindReplace::shouldRestart (  ) 

Définition à la ligne 934 du fichier KoSearchDia.cpp.

Références m_doCounting, m_find, et m_replace.

Référencé par findNext().

Voici le graphe d'appel pour cette fonction :

bool KoFindReplace::findNext (  ) 

Look for the next match. Returns false if we're finished.

Définition à la ligne 255 du fichier KoSearchDia.cpp.

Références KoTextIterator::atEnd(), KoTextIterator::currentTextAndIndex(), emitUndoRedo(), m_bInit, m_currentParagraphModified, m_find, m_matchingIndex, m_offset, m_replace, m_textIterator, needData(), KoTextIterator::options(), removeHighlight(), KoTextIterator::restart(), setData(), KoTextIterator::setOptions(), et shouldRestart().

Référencé par connectFind(), findPrevious(), et slotFindNext().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

bool KoFindReplace::findPrevious (  ) 

Look for the previous match. Returns false if we're finished.

Définition à la ligne 315 du fichier KoSearchDia.cpp.

Références findNext(), options(), et setOptions().

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::setActiveWindow (  ) 

Bring to front (e.g. when menuitem called twice)

Définition à la ligne 497 du fichier KoSearchDia.cpp.

Références testguiqt::dialog, m_find, et m_replace.

void KoFindReplace::emitUndoRedo (  ) 

Emit undo/redo command for the last replacements made.

Définition à la ligne 235 du fichier KoSearchDia.cpp.

Références emitNewCommand(), et m_macroCmd.

Référencé par dialogClosed(), et findNext().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

virtual void KoFindReplace::emitNewCommand ( KCommand *   )  [pure virtual]

Référencé par emitUndoRedo().

Voici le graphe d'appel pour cette fonction :

virtual void KoFindReplace::highlightPortion ( KoTextParag parag,
int  index,
int  length,
KoTextDocument textdoc,
KDialog *  dialog 
) [pure virtual]

Highlight a match.

Référencé par highlight().

bool KoFindReplace::validateMatch ( const QString &  text,
int  index,
int  matchedlength 
)

For KoTextFind and KoTextReplace

Définition à la ligne 846 du fichier KoSearchDia.cpp.

Références KoTextString::at(), KoSearchContext::Attribute, KoSearchContext::BgColor, KoSearchContext::Bold, KoSearchContext::Color, currentParag(), KoSearchContext::Family, KoTextParag::format(), KoSearchContext::Italic, KoSearchContext::Language, KoSearchContext::m_attribute, KoSearchContext::m_backGroundColor, KoSearchContext::m_color, KoSearchContext::m_family, KoSearchContext::m_language, KoSearchContext::m_options, KoSearchContext::m_optionsMask, m_searchContext, m_searchContextEnabled, KoSearchContext::m_size, KoSearchContext::m_strikeOut, KoSearchContext::m_underline, KoSearchContext::m_vertAlign, KoSearchContext::Shadow, KoSearchContext::Size, KoSearchContext::StrikeOut, KoTextParag::string(), KoSearchContext::Underline, KoSearchContext::VertAlign, et KoSearchContext::WordByWord.

Référencé par KoTextReplace::validateMatch(), et KoTextFind::validateMatch().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::replaceWithAttribut ( KoTextCursor cursor,
int  index 
) [protected]

Définition à la ligne 410 du fichier KoSearchDia.cpp.

Références KoTextParag::at(), KoSearchContext::BgColor, KoTextFormat::Bold, KoSearchContext::Bold, KoTextFormat::Color, KoSearchContext::Color, KoTextIterator::currentParag(), KoTextIterator::currentTextObject(), KoTextFormat::ExtendUnderLine, KoTextFormat::Family, KoSearchContext::Family, KoTextStringChar::format, KoTextDocument::HighlightSelection, KoTextFormat::Italic, KoSearchContext::Italic, KoTextFormat::Language, KoSearchContext::Language, KoSearchContext::m_backGroundColor, KoSearchContext::m_color, KoSearchContext::m_family, KoSearchContext::m_language, KoSearchContext::m_options, KoSearchContext::m_optionsMask, m_replaceContext, KoSearchContext::m_size, KoSearchContext::m_strikeOut, m_textIterator, KoSearchContext::m_underline, KoSearchContext::m_vertAlign, macroCommand(), KoTextFormat::setBold(), KoTextFormat::setColor(), KoTextFormat::setFamily(), KoTextObject::setFormatCommand(), KoTextFormat::setItalic(), KoTextFormat::setLanguage(), KoTextFormat::setPointSize(), KoTextFormat::setShadow(), KoTextFormat::setStrikeOutType(), KoTextFormat::setTextBackgroundColor(), KoTextFormat::setUnderlineType(), KoTextFormat::setVAlign(), KoTextFormat::setWordByWord(), KoSearchContext::Shadow, KoTextFormat::ShadowText, KoTextFormat::Size, KoSearchContext::Size, KoTextFormat::StrikeOut, KoSearchContext::StrikeOut, KoTextFormat::TextBackgroundColor, KoSearchContext::Underline, KoTextFormat::VAlign, KoSearchContext::VertAlign, KoTextFormat::WordByWord, et KoSearchContext::WordByWord.

Référencé par replace().

Voici le graphe d'appel pour cette fonction :

KMacroCommand * KoFindReplace::macroCommand (  )  [protected]

Définition à la ligne 489 du fichier KoSearchDia.cpp.

Références m_macroCmd.

Référencé par replace(), et replaceWithAttribut().

Voici le graphe d'appel pour cette fonction :

long KoFindReplace::options (  )  const [protected]

Définition à la ligne 331 du fichier KoSearchDia.cpp.

Références m_find, et m_replace.

Référencé par findPrevious(), optionsChanged(), et replace().

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::setOptions ( long  opt  )  [protected]

Définition à la ligne 336 du fichier KoSearchDia.cpp.

Références m_find, m_replace, m_textIterator, et KoTextIterator::setOptions().

Référencé par findPrevious().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::removeHighlight (  )  [protected]

Définition à la ligne 228 du fichier KoSearchDia.cpp.

Références m_lastTextObjectHighlighted, et KoTextObject::removeHighlight().

Référencé par dialogClosed(), findNext(), et ~KoFindReplace().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

bool KoFindReplace::needData (  )  const [inline, protected]

Définition à la ligne 252 du fichier KoSearchDia.h.

Référencé par findNext().

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::setData ( const QString &  data,
int  startPos = -1 
) [inline, protected]

Définition à la ligne 253 du fichier KoSearchDia.h.

Référencé par findNext().

Voici le graphe d'appel pour cette fonction :

void KoFindReplace::slotFindNext (  )  [protected, slot]

Définition à la ligne 309 du fichier KoSearchDia.cpp.

Références findNext().

Référencé par connectFind().

void KoFindReplace::optionsChanged (  )  [protected, slot]

Définition à la ligne 214 du fichier KoSearchDia.cpp.

Références m_textIterator, options(), et KoTextIterator::setOptions().

Référencé par connectFind().

void KoFindReplace::dialogClosed (  )  [protected, slot]

Définition à la ligne 219 du fichier KoSearchDia.cpp.

Références emitUndoRedo(), m_doCounting, et removeHighlight().

Référencé par connectFind().

void KoFindReplace::highlight ( const QString &  text,
int  matchingIndex,
int  matchingLength 
) [protected, slot]

Définition à la ligne 353 du fichier KoSearchDia.cpp.

Références KoTextIterator::currentParag(), KoTextIterator::currentTextObject(), testguiqt::dialog, highlightPortion(), m_find, m_lastTextObjectHighlighted, m_matchingIndex, m_offset, m_replace, m_textIterator, KoTextObject::removeHighlight(), et KoTextObject::textDocument().

Référencé par connectFind(), et replace().

void KoFindReplace::replace ( const QString &  text,
int  replacementIndex,
int  replacedLength,
int  searchLength 
) [protected, slot]

Définition à la ligne 365 du fichier KoSearchDia.cpp.

Références KoTextIterator::currentParag(), KoTextIterator::currentTextObject(), KoTextObject::DefaultInsertFlags, KoTextObject::DoNotRepaint, highlight(), KoTextDocument::HighlightSelection, m_matchingIndex, m_offset, KoSearchContext::m_optionsMask, m_replaceContext, m_textIterator, macroCommand(), options(), KoTextObject::replaceSelectionCommand(), replaceWithAttribut(), KoTextCursor::setIndex(), KoTextObject::setNeedSpellCheck(), KoTextCursor::setParag(), slotCurrentParagraphModified(), et KoTextObject::textDocument().

Référencé par KoFindReplace().

void KoFindReplace::slotCurrentParagraphModified ( int  ,
int  ,
int   
) [protected, slot]

Définition à la ligne 345 du fichier KoSearchDia.cpp.

Références m_currentParagraphModified, et m_offset.

Référencé par connectFind(), et replace().

void KoFindReplace::connectFind ( KFind *  find  )  [private]

Définition à la ligne 184 du fichier KoSearchDia.cpp.

Références dialogClosed(), findNext(), highlight(), m_bInit, m_currentParagraphModified, m_matchingIndex, m_textIterator, optionsChanged(), slotCurrentParagraphModified(), et slotFindNext().

Référencé par KoFindReplace().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :


Documentation des données membres

KoTextFind* KoFindReplace::m_find [private]

Définition à la ligne 270 du fichier KoSearchDia.h.

Référencé par findNext(), highlight(), KoFindReplace(), options(), setActiveWindow(), setOptions(), shouldRestart(), et ~KoFindReplace().

KoTextReplace* KoFindReplace::m_replace [private]

Définition à la ligne 271 du fichier KoSearchDia.h.

Référencé par findNext(), highlight(), KoFindReplace(), options(), setActiveWindow(), setOptions(), shouldRestart(), et ~KoFindReplace().

KoSearchContext KoFindReplace::m_searchContext [private]

Définition à la ligne 273 du fichier KoSearchDia.h.

Référencé par validateMatch().

KoSearchContext KoFindReplace::m_replaceContext [private]

Définition à la ligne 274 du fichier KoSearchDia.h.

Référencé par replace(), et replaceWithAttribut().

bool KoFindReplace::m_searchContextEnabled [private]

Définition à la ligne 275 du fichier KoSearchDia.h.

Référencé par validateMatch().

bool KoFindReplace::m_doCounting [private]

Définition à la ligne 276 du fichier KoSearchDia.h.

Référencé par dialogClosed(), et shouldRestart().

bool KoFindReplace::m_bInit [private]

Définition à la ligne 277 du fichier KoSearchDia.h.

Référencé par connectFind(), et findNext().

bool KoFindReplace::m_currentParagraphModified [private]

Définition à la ligne 278 du fichier KoSearchDia.h.

Référencé par connectFind(), findNext(), et slotCurrentParagraphModified().

KMacroCommand* KoFindReplace::m_macroCmd [private]

Définition à la ligne 280 du fichier KoSearchDia.h.

Référencé par emitUndoRedo(), et macroCommand().

int KoFindReplace::m_offset [private]

Définition à la ligne 281 du fichier KoSearchDia.h.

Référencé par findNext(), highlight(), replace(), et slotCurrentParagraphModified().

int KoFindReplace::m_matchingIndex [private]

Définition à la ligne 282 du fichier KoSearchDia.h.

Référencé par connectFind(), findNext(), highlight(), et replace().

KoTextIterator KoFindReplace::m_textIterator [private]

Définition à la ligne 284 du fichier KoSearchDia.h.

Référencé par connectFind(), findNext(), highlight(), optionsChanged(), replace(), replaceWithAttribut(), et setOptions().

KoTextObject* KoFindReplace::m_lastTextObjectHighlighted [private]

Définition à la ligne 287 du fichier KoSearchDia.h.

Référencé par highlight(), et removeHighlight().


La documentation de cette classe a été générée à partir des fichiers suivants :
Généré le Wed Nov 22 23:45:36 2006 pour KPlato par  doxygen 1.5.1-p1