LibreOffice Module sw (master) 1
|
Text portion for the Format -> Paragraph -> Drop Caps functionality. More...
#include <pordrop.hxx>
Public Member Functions | |
SwDropPortion (const sal_uInt16 nLineCnt, const sal_uInt16 nDropHeight, const sal_uInt16 nDropDescent, const sal_uInt16 nDistance) | |
SwDropPortion CTor, DTor. More... | |
virtual | ~SwDropPortion () override |
virtual void | Paint (const SwTextPaintInfo &rInf) const override |
void | PaintDrop (const SwTextPaintInfo &rInf) const |
virtual bool | Format (SwTextFormatInfo &rInf) override |
virtual SwPosSize | GetTextSize (const SwTextSizeInfo &rInfo) const override |
virtual TextFrameIndex | GetModelPositionForViewPoint (sal_uInt16 nOfst) const override |
the parameter is actually SwTwips apparently? More... | |
sal_uInt16 | GetLines () const |
sal_uInt16 | GetDistance () const |
sal_uInt16 | GetDropHeight () const |
sal_uInt16 | GetDropDescent () const |
sal_uInt16 | GetDropLeft () const |
SwDropPortionPart * | GetPart () const |
void | SetPart (std::unique_ptr< SwDropPortionPart > pNew) |
void | SetY (short nNew) |
SwFont * | GetFnt () const |
Public Member Functions inherited from SwTextPortion | |
SwTextPortion () | |
virtual void | Paint (const SwTextPaintInfo &rInf) const override |
virtual bool | Format (SwTextFormatInfo &rInf) override |
virtual void | FormatEOL (SwTextFormatInfo &rInf) override |
virtual TextFrameIndex | GetModelPositionForViewPoint (sal_uInt16 nOfst) const override |
the parameter is actually SwTwips apparently? More... | |
virtual SwPosSize | GetTextSize (const SwTextSizeInfo &rInfo) const override |
virtual bool | GetExpText (const SwTextSizeInfo &rInf, OUString &rText) const override |
virtual tools::Long | CalcSpacing (tools::Long nSpaceAdd, const SwTextSizeInfo &rInf) const override |
TextFrameIndex | GetSpaceCnt (const SwTextSizeInfo &rInf, TextFrameIndex &rCnt) const |
bool | CreateHyphen (SwTextFormatInfo &rInf, SwTextGuess const &rGuess) |
virtual void | HandlePortion (SwPortionHandler &rPH) const override |
Public Member Functions inherited from SwLinePortion | |
SwLinePortion (const SwLinePortion &rPortion) | |
virtual | ~SwLinePortion () |
SwLinePortion * | GetNextPortion () const |
SwLinePortion & | operator= (const SwLinePortion &rPortion) |
TextFrameIndex | GetLen () const |
void | SetLen (TextFrameIndex const nLen) |
void | SetNextPortion (SwLinePortion *pNew) |
SwTwips & | GetAscent () |
SwTwips | GetAscent () const |
void | SetAscent (const SwTwips nNewAsc) |
void | PrtWidth (SwTwips nNewWidth) |
SwTwips | PrtWidth () const |
void | AddPrtWidth (const SwTwips nNew) |
void | SubPrtWidth (const SwTwips nNew) |
SwTwips | ExtraBlankWidth () const |
void | ExtraBlankWidth (const SwTwips nNew) |
SwTwips | GetHangingBaseline () const |
void | SetHangingBaseline (const SwTwips nNewBaseline) |
virtual SwLinePortion * | Insert (SwLinePortion *pPortion) |
virtual SwLinePortion * | Append (SwLinePortion *pPortion) |
SwLinePortion * | Cut (SwLinePortion *pVictim) |
void | Truncate () |
virtual SwLinePortion * | Compress () |
void | SetWhichPor (const PortionType nNew) |
PortionType | GetWhichPor () const |
bool | InTextGrp () const |
bool | InGlueGrp () const |
bool | InTabGrp () const |
bool | InHyphGrp () const |
bool | InNumberGrp () const |
bool | InFixGrp () const |
bool | InFieldGrp () const |
bool | InToxRefGrp () const |
bool | InToxRefOrFieldGrp () const |
bool | InExpGrp () const |
bool | InFixMargGrp () const |
bool | InSpaceGrp () const |
bool | IsGrfNumPortion () const |
bool | IsFlyCntPortion () const |
bool | IsBlankPortion () const |
bool | IsBreakPortion () const |
bool | IsErgoSumPortion () const |
bool | IsQuoVadisPortion () const |
bool | IsTabLeftPortion () const |
bool | IsTabRightPortion () const |
bool | IsTabCenterPortion () const |
bool | IsTabDecimalPortion () const |
bool | IsFootnoteNumPortion () const |
bool | IsFootnotePortion () const |
bool | IsDropPortion () const |
bool | IsLayPortion () const |
bool | IsParaPortion () const |
bool | IsMarginPortion () const |
bool | IsFlyPortion () const |
bool | IsHolePortion () const |
bool | IsSoftHyphPortion () const |
bool | IsPostItsPortion () const |
bool | IsCombinedPortion () const |
bool | IsTextPortion () const |
bool | IsHangingPortion () const |
bool | IsKernPortion () const |
bool | IsArrowPortion () const |
bool | IsMultiPortion () const |
bool | IsNumberPortion () const |
bool | IsControlCharPortion () const |
SwLinePortion * | FindPrevPortion (const SwLinePortion *pRoot) |
SwLinePortion * | FindLastPortion () |
virtual TextFrameIndex | GetModelPositionForViewPoint (sal_uInt16 nOfst) const |
the parameter is actually SwTwips apparently? More... | |
virtual SwPosSize | GetTextSize (const SwTextSizeInfo &rInfo) const |
void | CalcTextSize (const SwTextSizeInfo &rInfo) |
virtual void | Paint (const SwTextPaintInfo &rInf) const =0 |
void | PrePaint (const SwTextPaintInfo &rInf, const SwLinePortion *pLast) const |
virtual bool | Format (SwTextFormatInfo &rInf) |
virtual void | FormatEOL (SwTextFormatInfo &rInf) |
void | Move (SwTextPaintInfo &rInf) |
virtual bool | GetExpText (const SwTextSizeInfo &rInf, OUString &rText) const |
virtual sal_uInt16 | GetViewWidth (const SwTextSizeInfo &rInf) const |
virtual tools::Long | CalcSpacing (tools::Long nSpaceAdd, const SwTextSizeInfo &rInf) const |
virtual void | HandlePortion (SwPortionHandler &rPH) const |
bool | GetJoinBorderWithPrev () const |
bool | GetJoinBorderWithNext () const |
void | SetJoinBorderWithPrev (const bool bJoinPrev) |
void | SetJoinBorderWithNext (const bool bJoinNext) |
virtual void | dumpAsXml (xmlTextWriterPtr pWriter, const OUString &rText, TextFrameIndex &rOffset) const |
void | dumpAsXmlAttributes (xmlTextWriterPtr writer, std::u16string_view rText, TextFrameIndex nOffset) const |
Public Member Functions inherited from SwPosSize | |
SwPosSize (const SwTwips nW=0, const SwTwips nH=0) | |
SwPosSize (const Size &rSize) | |
virtual | ~SwPosSize () |
SwPosSize (SwPosSize const &)=default | |
SwPosSize (SwPosSize &&)=default | |
SwPosSize & | operator= (SwPosSize const &)=default |
SwPosSize & | operator= (SwPosSize &&)=default |
SwTwips | Height () const |
virtual void | Height (const SwTwips nNew, const bool=true) |
SwTwips | Width () const |
void | Width (const SwTwips nNew) |
Size | SvLSize () const |
void | SvLSize (const Size &rSize) |
void | SvXSize (const Size &rSize) |
SwPosSize & | operator= (const Size &rSize) |
Static Public Member Functions | |
static void | DeleteDropCapCache () |
Static Public Member Functions inherited from SwTextPortion | |
static SwTextPortion * | CopyLinePortion (const SwLinePortion &rPortion) |
Private Member Functions | |
bool | FormatText (SwTextFormatInfo &rInf) |
void | PaintText (const SwTextPaintInfo &rInf) const |
Manipulate the width, otherwise the chars are being stretched. More... | |
Private Attributes | |
std::unique_ptr< SwDropPortionPart > | m_pPart |
sal_uInt16 | m_nLines |
sal_uInt16 | m_nDropHeight |
sal_uInt16 | m_nDropDescent |
sal_uInt16 | m_nDistance |
sal_uInt16 | m_nFix |
short | m_nY |
Friends | |
class | SwDropCapCache |
Additional Inherited Members | |
Protected Member Functions inherited from SwLinePortion | |
SwLinePortion () | |
Protected Attributes inherited from SwLinePortion | |
SwLinePortion * | mpNextPortion |
TextFrameIndex | mnLineLength |
SwTwips | mnAscent |
SwTwips | mnHangingBaseline |
Text portion for the Format -> Paragraph -> Drop Caps functionality.
Definition at line 64 of file pordrop.hxx.
SwDropPortion::SwDropPortion | ( | const sal_uInt16 | nLineCnt, |
const sal_uInt16 | nDropHeight, | ||
const sal_uInt16 | nDropDescent, | ||
const sal_uInt16 | nDistance | ||
) |
SwDropPortion CTor, DTor.
Definition at line 105 of file txtdrop.cxx.
References Drop, and SwLinePortion::SetWhichPor().
|
overridevirtual |
Definition at line 119 of file txtdrop.cxx.
References m_pPart.
|
static |
|
overridevirtual |
Reimplemented from SwTextPortion.
Definition at line 996 of file txtdrop.cxx.
References SwDropCapCache::CalcFontSize(), SwTextPortion::CalcSpacing(), SwTextPortion::Format(), FormatText(), SwTextSizeInfo::GetAscent(), GetDistance(), SwDropPortionPart::GetFollow(), SwDropPortionPart::GetFont(), SwTextSizeInfo::GetIdx(), SwDropPortionPart::GetJoinBorderWithNext(), SwDropPortionPart::GetJoinBorderWithPrev(), SwTextSizeInfo::GetLen(), SwDropPortionPart::GetLen(), SwTextSizeInfo::GetOut(), SwTextPaintInfo::GetSpaceAdd(), SwTextSizeInfo::GetTextHeight(), SwPosSize::Height(), SwLinePortion::InSpaceGrp(), lcl_IsDropFlyInter(), m_nDistance, m_nDropHeight, m_nFix, m_nLines, m_pPart, pDropCapCache, SwLinePortion::SetAscent(), SwLayoutModeModifier::SetAuto(), SwTextFormatInfo::SetDropInit(), SwTextSizeInfo::SetIdx(), SwLinePortion::SetJoinBorderWithNext(), SwLinePortion::SetJoinBorderWithPrev(), SwTextSizeInfo::SetLen(), SwLinePortion::SetLen(), SwDropPortionPart::SetWidth(), SwDropCapCache, SwTextFormatInfo::Width(), SwPosSize::Width(), and SwTextPaintInfo::X().
|
private |
Definition at line 420 of file txtdrop.cxx.
References SwTextPortion::Format(), SwTextSizeInfo::GetLen(), SwLinePortion::GetLen(), SwTextSizeInfo::SetLen(), SwLinePortion::SetLen(), SwTextFormatInfo::SetUnderflow(), and SwLinePortion::Truncate().
Referenced by Format().
|
inline |
|
inline |
Definition at line 94 of file pordrop.hxx.
References m_nDropDescent.
Referenced by SwTextMargin::DropInit(), SwTextCursor::GetCharRect_(), and SwTextNode::GetDropSize().
|
inline |
Definition at line 93 of file pordrop.hxx.
References m_nDropHeight.
Referenced by SwDropCapCache::CalcFontSize(), SwTextMargin::DropInit(), and SwTextNode::GetDropSize().
|
inline |
Definition at line 95 of file pordrop.hxx.
References m_nFix, and SwPosSize::Width().
Referenced by SwTextMargin::DropInit().
|
inline |
Definition at line 102 of file pordrop.hxx.
References m_pPart.
Referenced by SwTextNode::GetDropSize(), and SwTextCursor::GetModelPositionForViewPoint().
|
inline |
Definition at line 91 of file pordrop.hxx.
References m_nLines.
Referenced by SwLineLayout::CalcLine(), SwTextMargin::DropInit(), SwTextCursor::GetCharRect_(), SwTextCursor::GetModelPositionForViewPoint(), and SwTextFormatter::MergeCharacterBorder().
|
overridevirtual |
the parameter is actually SwTwips apparently?
Reimplemented from SwTextPortion.
Definition at line 479 of file txtdrop.cxx.
|
inline |
Definition at line 97 of file pordrop.hxx.
References m_pPart.
Referenced by SwDropCapCache::CalcFontSize(), SwTextCursor::GetCharRect_(), SwTextCursor::GetModelPositionForViewPoint(), GetTextSize(), SwTextFormatter::MergeCharacterBorder(), and PaintText().
|
overridevirtual |
Reimplemented from SwTextPortion.
Definition at line 436 of file txtdrop.cxx.
References SwDropPortionPart::GetFollow(), SwDropPortionPart::GetFont(), SwTextSizeInfo::GetIdx(), SwDropPortionPart::GetJoinBorderWithNext(), SwDropPortionPart::GetJoinBorderWithPrev(), SwTextSizeInfo::GetLen(), SwDropPortionPart::GetLen(), GetPart(), SwTextPortion::GetTextSize(), SwDropPortionPart::GetWidth(), SwLinePortion::SetJoinBorderWithNext(), SwLinePortion::SetJoinBorderWithPrev(), SwLinePortion::SetLen(), and SwPosSize::Width().
|
overridevirtual |
Reimplemented from SwTextPortion.
Definition at line 394 of file txtdrop.cxx.
References SwTextPaintInfo::DrawBackground(), SwTextSizeInfo::GetFont(), SwTextSizeInfo::GetOpt(), SwFont::GetOrientation(), SwTextSizeInfo::GetOut(), SwTextSizeInfo::GetTextFrame(), SwViewOption::IsFieldShadings(), SwViewOption::IsPagePreview(), SwViewOption::IsReadonly(), SwFrame::IsVertical(), m_nDropHeight, m_nLines, m_pPart, SwTextSizeInfo::OnWin(), SwTextPortion::Paint(), and SwLayoutModeModifier::SetAuto().
void SwDropPortion::PaintDrop | ( | const SwTextPaintInfo & | rInf | ) | const |
Definition at line 349 of file txtdrop.cxx.
References SwSaveClip::ChgClip(), SwLinePortion::GetAscent(), SwTextSizeInfo::GetOut(), SwTextPaintInfo::GetPaintRect(), SwTextInfo::GetParaPortion(), SwLineLayout::GetRealHeight(), SwTextSizeInfo::GetTextFrame(), SwPosSize::Height(), SwLineLayout::Height(), SwRect::Intersection(), m_nDropDescent, m_nDropHeight, m_nLines, m_pPart, SwTextSizeInfo::OnWin(), PaintText(), SwLinePortion::SetAscent(), SwPosSize::SvLSize(), SwPosSize::Width(), SwTextPaintInfo::X(), Y, Point::Y(), and SwTextPaintInfo::Y().
Referenced by SwTextPainter::PaintDropPortion().
|
private |
Manipulate the width, otherwise the chars are being stretched.
Definition at line 301 of file txtdrop.cxx.
References COL_TRANSPARENT(), SwTextPaintInfo::DrawBackground(), SwLinePortion::GetAscent(), SwFont::GetBackColor(), SwDropPortionPart::GetFollow(), SwDropPortionPart::GetFont(), SwTextSizeInfo::GetIdx(), SwDropPortionPart::GetJoinBorderWithNext(), SwDropPortionPart::GetJoinBorderWithPrev(), SwDropPortionPart::GetLen(), SwLinePortion::GetLen(), SwTextSizeInfo::GetOpt(), SwTextSizeInfo::GetOut(), GetPart(), SwDropPortionPart::GetWidth(), SwViewOption::IsFieldShadings(), SwViewOption::IsPagePreview(), SwViewOption::IsReadonly(), m_nDropHeight, m_nLines, m_nY, m_pPart, SwTextSizeInfo::OnWin(), SwTextPortion::Paint(), SwLinePortion::SetAscent(), SwLayoutModeModifier::SetAuto(), SwLinePortion::SetJoinBorderWithNext(), SwLinePortion::SetJoinBorderWithPrev(), SwLinePortion::SetLen(), SwPosSize::Width(), X, SwTextPaintInfo::X(), Y, and SwTextPaintInfo::Y().
Referenced by PaintDrop().
|
inline |
Definition at line 98 of file pordrop.hxx.
References m_pPart.
Referenced by SwTextFormatter::NewDropPortion().
|
inline |
Definition at line 100 of file pordrop.hxx.
References m_nY.
Referenced by SwDropCapCache::CalcFontSize().
|
friend |
Definition at line 66 of file pordrop.hxx.
Referenced by Format().
|
private |
Definition at line 71 of file pordrop.hxx.
Referenced by Format(), and GetDistance().
|
private |
Definition at line 70 of file pordrop.hxx.
Referenced by GetDropDescent(), and PaintDrop().
|
private |
Definition at line 69 of file pordrop.hxx.
Referenced by Format(), GetDropHeight(), Paint(), PaintDrop(), and PaintText().
|
private |
Definition at line 72 of file pordrop.hxx.
Referenced by Format(), and GetDropLeft().
|
private |
Definition at line 68 of file pordrop.hxx.
Referenced by Format(), GetLines(), Paint(), PaintDrop(), and PaintText().
|
private |
Definition at line 73 of file pordrop.hxx.
Referenced by PaintText(), and SetY().
|
private |
Definition at line 67 of file pordrop.hxx.
Referenced by Format(), GetFnt(), GetPart(), Paint(), PaintDrop(), PaintText(), SetPart(), and ~SwDropPortion().