LibreOffice Module sw (master) 1
Namespaces | Typedefs | Functions
findattr.cxx File Reference
#include <com/sun/star/lang/Locale.hpp>
#include <com/sun/star/util/SearchAlgorithms2.hpp>
#include <com/sun/star/util/SearchFlags.hpp>
#include <i18nlangtag/languagetag.hxx>
#include <i18nutil/searchopt.hxx>
#include <osl/diagnose.h>
#include <unotools/syslocale.hxx>
#include <hintids.hxx>
#include <svl/itemiter.hxx>
#include <svl/srchitem.hxx>
#include <svl/whiter.hxx>
#include <editeng/colritem.hxx>
#include <editeng/fontitem.hxx>
#include <fmtpdsc.hxx>
#include <txatbase.hxx>
#include <charfmt.hxx>
#include <crsrsh.hxx>
#include <doc.hxx>
#include <IDocumentUndoRedo.hxx>
#include <IDocumentState.hxx>
#include <swcrsr.hxx>
#include <ndtxt.hxx>
#include <pamtyp.hxx>
#include <txtfrm.hxx>
#include <swundo.hxx>
#include <optional>
#include <algorithm>
#include <memory>
Include dependency graph for findattr.cxx:

Go to the source code of this file.


namespace  sw
 Dialog to specify the properties of date form field.


typedef bool(* FnSearchAttr) (const SwTextNode &, SwAttrCheckArr &, SwPaM &)


static bool CmpAttr (const SfxPoolItem &rItem1, const SfxPoolItem &rItem2)
const SwTextAttrGetFrwrdTextHint (const SwpHints &rHtsArr, size_t &rPos, sal_Int32 nContentPos)
const SwTextAttrGetBkwrdTextHint (const SwpHints &rHtsArr, size_t &rPos, sal_Int32 nContentPos)
static void lcl_SetAttrPam (SwPaM &rPam, sal_Int32 nStart, const sal_Int32 *pEnd, const bool bSaveMark)
static bool lcl_SearchAttr (const SwTextNode &rTextNd, SwPaM &rPam, const SfxPoolItem &rCmpItem, SwMoveFnCollection const &fnMove)
 search for a text attribute More...
static bool lcl_IsAttributeIgnorable (sal_Int32 const nNdStart, sal_Int32 const nNdEnd, SwSrchChrAttr const &rTmp)
static bool lcl_SearchForward (const SwTextNode &rTextNd, SwAttrCheckArr &rCmpArr, SwPaM &rPam)
static bool lcl_SearchBackward (const SwTextNode &rTextNd, SwAttrCheckArr &rCmpArr, SwPaM &rPam)
static bool lcl_Search (const SwContentNode &rCNd, const SfxItemSet &rCmpSet, bool bNoColls)
bool sw::FindAttrImpl (SwPaM &rSearchPam, const SfxPoolItem &rAttr, SwMoveFnCollection const &fnMove, const SwPaM &rRegion, bool bInReadOnly, SwRootFrame const *const pLayout)
static bool FindAttrsImpl (SwPaM &rSearchPam, const SfxItemSet &rSet, bool bNoColls, SwMoveFnCollection const &fnMove, const SwPaM &rRegion, bool bInReadOnly, bool bMoveFirst, SwRootFrame const *const pLayout)

Typedef Documentation

◆ FnSearchAttr

typedef bool(* FnSearchAttr) (const SwTextNode &, SwAttrCheckArr &, SwPaM &)

Definition at line 1040 of file findattr.cxx.

Function Documentation

◆ CmpAttr()

static bool CmpAttr ( const SfxPoolItem rItem1,
const SfxPoolItem rItem2 

◆ FindAttrsImpl()

static bool FindAttrsImpl ( SwPaM rSearchPam,
const SfxItemSet rSet,
bool  bNoColls,
SwMoveFnCollection const &  fnMove,
const SwPaM rRegion,
bool  bInReadOnly,
bool  bMoveFirst,
SwRootFrame const *const  pLayout 

◆ GetBkwrdTextHint()

const SwTextAttr * GetBkwrdTextHint ( const SwpHints rHtsArr,
size_t &  rPos,
sal_Int32  nContentPos 

Definition at line 89 of file findattr.cxx.

References SwpHints::Get(), and SwTextAttr::GetStart().

◆ GetFrwrdTextHint()

const SwTextAttr * GetFrwrdTextHint ( const SwpHints rHtsArr,
size_t &  rPos,
sal_Int32  nContentPos 

Definition at line 76 of file findattr.cxx.

References SwpHints::Count(), SwpHints::Get(), and SwTextAttr::GetStart().

◆ lcl_IsAttributeIgnorable()

static bool lcl_IsAttributeIgnorable ( sal_Int32 const  nNdStart,
sal_Int32 const  nNdEnd,
SwSrchChrAttr const &  rTmp 

Definition at line 307 of file findattr.cxx.

◆ lcl_Search()

static bool lcl_Search ( const SwContentNode rCNd,
const SfxItemSet rCmpSet,
bool  bNoColls 

◆ lcl_SearchAttr()

static bool lcl_SearchAttr ( const SwTextNode rTextNd,
SwPaM rPam,
const SfxPoolItem rCmpItem,
SwMoveFnCollection const &  fnMove 

search for a text attribute

This function searches in a text node for a given attribute. If that is found then the SwPaM contains the section that surrounds the attribute (w.r.t. the search area).

rTextNdText node to search in.
Returns <true> if found, <false> otherwise.

Definition at line 138 of file findattr.cxx.

References SwpHints::Count(), SwTextAttr::End(), SwMoveFnCollection::fnGetHint, fnMoveForward, SwPosition::GetContentIndex(), SwPaM::GetPoint(), SwTextAttr::GetStart(), SwTextNode::GetSwpHints(), SwTextNode::HasHints(), lcl_SetAttrPam(), nPos, SfxPoolItem::Which(), and SwTextAttr::Which().

Referenced by sw::FindAttrImpl().

◆ lcl_SearchBackward()

static bool lcl_SearchBackward ( const SwTextNode rTextNd,
SwAttrCheckArr &  rCmpArr,
SwPaM rPam 

◆ lcl_SearchForward()

static bool lcl_SearchForward ( const SwTextNode rTextNd,
SwAttrCheckArr &  rCmpArr,
SwPaM rPam 

◆ lcl_SetAttrPam()

static void lcl_SetAttrPam ( SwPaM rPam,
sal_Int32  nStart,
const sal_Int32 *  pEnd,
const bool  bSaveMark