LibreOffice Module sw (master) 1
|
Go to the source code of this file.
Namespaces | |
namespace | com |
namespace | com::sun |
namespace | com::sun::star |
namespace | com::sun::star::awt |
namespace | weld |
namespace | model |
Functions | |
SW_DLLPUBLIC void | PrepareBoxInfo (SfxItemSet &rSet, const SwWrtShell &rSh) |
SW_DLLPUBLIC void | ConvertAttrCharToGen (SfxItemSet &rSet, bool bPara=false) |
Convert character specific attributes to general ones used by tab pages. More... | |
SW_DLLPUBLIC void | ConvertAttrGenToChar (SfxItemSet &rSet, const SfxItemSet &rOrigSet, bool bPara=false) |
Convert general attributes to the corresponding character attributes. More... | |
void | ApplyCharBackground (Color const &rBackgroundColor, model::ComplexColor const &rComplexColor, SwWrtShell &rShell) |
Apply character background on the shell. More... | |
void | ItemSetToPageDesc (const SfxItemSet &rSet, SwPageDesc &rPageDesc) |
void | PageDescToItemSet (const SwPageDesc &rPageDesc, SfxItemSet &rSet) |
SW_DLLPUBLIC void | MakeDefTabs (SwTwips nDefDist, SvxTabStopItem &rTabs) |
SW_DLLPUBLIC SwTwips | GetTabDist (const SvxTabStopItem &rTabs) |
void | SwToSfxPageDescAttr (SfxItemSet &rSet) |
void | SfxToSwPageDescAttr (const SwWrtShell &rShell, SfxItemSet &rSet) |
SW_DLLPUBLIC FieldUnit | GetDfltMetric (bool bWeb) |
void | SetDfltMetric (FieldUnit eMetric, bool bWeb) |
bool | HasCharUnit (bool bWeb) |
void | SetApplyCharUnit (bool bApplyChar, bool bWeb) |
SW_DLLPUBLIC void | FillCharStyleListBox (weld::ComboBox &rToFill, SwDocShell *pDocSh, bool bSorted=false, bool bWithDefault=false) |
SW_DLLPUBLIC void | InsertStringSorted (const OUString &rId, const OUString &rEntry, weld::ComboBox &rToFill, int nOffset) |
SwTwips | GetTableWidth (SwFrameFormat const *pFormat, SwTabCols const &rCols, sal_uInt16 *pPercent, SwWrtShell *pSh) |
OUString | GetAppLangDateTimeString (const DateTime &) |
bool | ExecuteMenuCommand (const css::uno::Reference< css::awt::XPopupMenu > &rMenu, const SfxViewFrame &rViewFrame, sal_uInt16 nId) |
void ApplyCharBackground | ( | Color const & | rBackgroundColor, |
model::ComplexColor const & | rComplexColor, | ||
SwWrtShell & | rShell | ||
) |
Apply character background on the shell.
Need to use this to hide the mixed character background and character highlighting attribute, which were added for MSO compatibility where there are two kind of character background.
[in] | rBackgroundColor | the color to apply on the shell |
[in,out] | rShell | the shell on which we apply the new attribute |
Definition at line 197 of file uitool.cxx.
References SwEditShell::EndUndo(), SwEditShell::GetCurAttr(), SfxGrabBagItem::GetGrabBag(), SfxItemSet::GetItemIfSet(), SfxShell::GetPool(), SwWrtShell::GetView(), INSATTR, RES_CHRATR_BACKGROUND(), RES_CHRATR_GRABBAG(), RES_CHRATR_HIGHLIGHT(), SwEditShell::SetAttrItem(), and SwEditShell::StartUndo().
Referenced by SwTextShell::Execute(), and SwEditWin::MouseButtonUp().
SW_DLLPUBLIC void ConvertAttrCharToGen | ( | SfxItemSet & | rSet, |
bool | bPara = false |
||
) |
Convert character specific attributes to general ones used by tab pages.
[in,out] | rSet | the set in which character attributes are stored |
[in] | bIsPara | is called by a paragraph style |
Definition at line 106 of file uitool.cxx.
References COL_TRANSPARENT(), SvxBrushItem::GetColor(), SfxGrabBagItem::GetGrabBag(), SfxItemSet::GetItemIfSet(), SfxItemSet::GetItemState(), SfxItemSet::GetRanges(), i, SfxItemSet::MergeRange(), SfxItemSet::Put(), RES_CHRATR_BACKGROUND(), RES_CHRATR_HIGHLIGHT(), RES_PARATR_GRABBAG(), rSet, and WhichRangesContainer::size().
Referenced by SwEnvFormatPage::Edit(), SwDocShell::Edit(), and sw_CharDialog().
SW_DLLPUBLIC void ConvertAttrGenToChar | ( | SfxItemSet & | rSet, |
const SfxItemSet & | rOrigSet, | ||
bool | bPara = false |
||
) |
Convert general attributes to the corresponding character attributes.
This method is used after executed a character dialog.
[in,out] | rSet | the set in which character attributes are stored |
[in] | rOrigSet | original itemset used as input for the dialog |
[in] | bIsPara | is called by a paragraph style |
Definition at line 145 of file uitool.cxx.
References SfxItemSet::ClearItem(), SfxGrabBagItem::GetGrabBag(), SfxItemSet::GetItemIfSet(), SfxItemSet::GetItemState(), i, SfxItemSet::Put(), RES_BACKGROUND(), RES_CHRATR_BACKGROUND(), RES_CHRATR_GRABBAG(), RES_CHRATR_HIGHLIGHT(), RES_PARATR_GRABBAG(), rSet, and SfxItemSet::SetRanges().
Referenced by SwEnvFormatPage::Edit(), IMPL_LINK_NOARG(), and sw_CharDialogResult().
bool ExecuteMenuCommand | ( | const css::uno::Reference< css::awt::XPopupMenu > & | rMenu, |
const SfxViewFrame & | rViewFrame, | ||
sal_uInt16 | nId | ||
) |
Definition at line 883 of file uitool.cxx.
References aSeq, aURL, SfxViewFrame::GetFrame(), SfxFrame::GetFrameInterface(), nId, and xFrame.
Referenced by SwEditWin::Command(), and SwView::ExecSpellPopup().
SW_DLLPUBLIC void FillCharStyleListBox | ( | weld::ComboBox & | rToFill, |
SwDocShell * | pDocSh, | ||
bool | bSorted = false , |
||
bool | bWithDefault = false |
||
) |
Definition at line 781 of file uitool.cxx.
References weld::ComboBox::append(), ChrFmt, weld::ComboBox::find_text(), SfxStyleSheetBasePool::First(), weld::Widget::freeze(), weld::ComboBox::get_count(), SwDoc::GetCharFormats(), SwDocShell::GetDoc(), SfxStyleSheetBase::GetName(), SwFormat::GetName(), SwStyleNameMapper::GetPoolIdFromUIName(), SwDocShell::GetStyleSheetPool(), i, InsertStringSorted(), SwFormat::IsDefault(), SfxStyleSheetBasePool::Next(), sId, SwCharFormats::size(), SwResId(), and weld::Widget::thaw().
Referenced by SwTemplateDlgController::PageCreated(), SwSvxNumBulletTabDialog::PageCreated(), SwDropCapsPage::Reset(), SwEndNoteOptionPage::SetShell(), SwTOXEntryTabPage::SetWrtShell(), SwOutlineSettingsTabPage::SetWrtShell(), SwCaptionOptPage::SwCaptionOptPage(), SwCharURLPage::SwCharURLPage(), and SwLineNumberingDlg::SwLineNumberingDlg().
OUString GetAppLangDateTimeString | ( | const DateTime & | rDT | ) |
Definition at line 863 of file uitool.cxx.
References LocaleDataWrapper::getDate(), SvtSysLocale::GetLocaleData(), and LocaleDataWrapper::getTime().
Referenced by SwTextShell::ExecField(), IMPL_LINK(), SwRedlineAcceptDlg::InsertChildren(), SwRedlineAcceptDlg::InsertParents(), lcl_GetRedlineHelp(), and sw::sidebarwindows::SidebarTextControl::RequestHelp().
SW_DLLPUBLIC FieldUnit GetDfltMetric | ( | bool | bWeb | ) |
Definition at line 756 of file uitool.cxx.
References SW_MOD.
Referenced by SwLabPage::DisplayFormat(), SwDocShell::Edit(), SwDrawTextShell::ExecFontWork(), SwTextShell::ExecInsert(), SwDrawShell::Execute(), SwDrawTextShell::Execute(), SwFrameShell::Execute(), SwTableShell::Execute(), SwTextShell::Execute(), SwGrfShell::Execute(), SwDrawBaseShell::Execute(), SwTableColumnPage::Init(), SwEditWin::MouseMove(), SwTemplateDlgController::PageCreated(), SwSvxNumBulletTabDialog::PageCreated(), SwSectionIndentTabPage::Reset(), SwColumnPage::Reset(), SwFramePage::Reset(), SwWrapTabPage::Reset(), SwFormatTablePage::Reset(), SwNumPositionTabPage::SetWrtShell(), SwModule::StateOther(), sw_CharDialog(), SwDropCapsPage::SwDropCapsPage(), SwEnvFormatPage::SwEnvFormatPage(), SwEnvPrtPage::SwEnvPrtPage(), SwLabFormatPage::SwLabFormatPage(), SwMailMergeLayoutPage::SwMailMergeLayoutPage(), SwTOXEntryTabPage::SwTOXEntryTabPage(), and sw::sidebar::WrapPropertyPanel::WrapPropertyPanel().
SW_DLLPUBLIC SwTwips GetTabDist | ( | const SvxTabStopItem & | rTabs | ) |
Definition at line 650 of file uitool.cxx.
References SvxTabStopItem::Count().
Referenced by SwModule::CreateItemSet(), SwEnvFormatPage::Edit(), SwView::ExecTabWin(), SwTextShell::Execute(), SwView::GetState(), and SwView::StateTabWin().
SwTwips GetTableWidth | ( | SwFrameFormat const * | pFormat, |
SwTabCols const & | rCols, | ||
sal_uInt16 * | pPercent, | ||
SwWrtShell * | pSh | ||
) |
Definition at line 822 of file uitool.cxx.
References FlyEmbeddedPrt, SwFEShell::GetAnyCurRect(), SwFEShell::GetFlyFrameFormat(), SwFormat::GetFrameSize(), SwFormatHoriOrient::GetHoriOrient(), SwFormat::GetHoriOrient(), SvxLRSpaceItem::GetLeft(), SwFormat::GetLRSpace(), SvxLRSpaceItem::GetRight(), SwTabCols::GetRight(), SvxSizeItem::GetWidth(), SwFormatFrameSize::GetWidthPercent(), PagePrt, and SwRect::Width().
Referenced by lcl_TableParamToItemSet().
bool HasCharUnit | ( | bool | bWeb | ) |
SW_DLLPUBLIC void InsertStringSorted | ( | const OUString & | rId, |
const OUString & | rEntry, | ||
weld::ComboBox & | rToFill, | ||
int | nOffset | ||
) |
Definition at line 768 of file uitool.cxx.
References CollatorWrapper::compareString(), weld::ComboBox::get_count(), weld::ComboBox::get_text(), GetAppCaseCollator(), weld::ComboBox::insert(), and nCount.
Referenced by FillCharStyleListBox(), lcl_InsertVectors(), and SwBreakDlg::SwBreakDlg().
void ItemSetToPageDesc | ( | const SfxItemSet & | rSet, |
SwPageDesc & | rPageDesc | ||
) |
Definition at line 278 of file uitool.cxx.
References SwPageDesc::ChgFirstShare(), SwPageDesc::ChgFooterShare(), SwPageDesc::ChgHeaderShare(), FillHdFt(), SwDoc::FindTextFormatCollByName(), Fixed, FN_PARAM_FTN_INFO, SfxItemSet::Get(), SwDoc::GetDfltTextFormatColl(), SwFormat::GetDoc(), SwFormat::GetFooter(), SwFormatFooter::GetFooterFormat(), SwFormat::GetHeader(), SwFormatHeader::GetHeaderFormat(), SwDoc::getIDocumentStylePoolAccess(), SfxItemSet::GetItemIfSet(), SfxItemSet::GetItemState(), SwPageDesc::GetMaster(), SvxPageItem::GetNumType(), SvxPageItem::GetPageUsage(), SwStyleNameMapper::GetPoolIdFromUIName(), SvxSizeItem::GetSize(), IDocumentStylePoolAccess::GetTextCollFromPool(), SfxBoolItem::GetValue(), SwFormatHeader::IsActive(), SwFormatFooter::IsActive(), SvxPageItem::IsLandscape(), lcl_convertUseFromSvx(), SwDoc::MakeTextFormatColl(), nId, RES_BACKGROUND_FULL_SIZE(), RES_RTL_GUTTER(), rSet, SwPageDesc::SetFootnoteInfo(), SwFormat::SetFormatAttr(), SwTextFormatColl::SetFormatAttr(), SwPageDesc::SetLandscape(), SvxNumberType::SetNumberingType(), SwPageDesc::SetNumType(), SwPageDesc::SetRegisterFormatColl(), SvxSizeItem::SetSize(), SwPageDesc::SetUseOn(), and TxtColl.
Referenced by SwView::Execute(), and SwDocStyleSheet::SetItemSet().
SW_DLLPUBLIC void MakeDefTabs | ( | SwTwips | nDefDist, |
SvxTabStopItem & | rTabs | ||
) |
Definition at line 638 of file uitool.cxx.
References SvxTabStopItem::Count(), and SvxTabStopItem::Insert().
Referenced by SwModule::ApplyItemSet(), SwEnvFormatPage::Edit(), SwView::ExecTabWin(), SwView::Execute(), and SwTextShell::Execute().
void PageDescToItemSet | ( | const SwPageDesc & | rPageDesc, |
SfxItemSet & | rSet | ||
) |
Definition at line 458 of file uitool.cxx.
References Fixed, SwFormat::GetAttrSet(), SwDoc::GetDfltFrameFormat(), SwFormat::GetDoc(), SwPageDesc::GetFollow(), SwFormat::GetFooter(), SwFormatFooter::GetFooterFormat(), SwPageDesc::GetFootnoteInfo(), SwFormat::GetFrameSize(), SwFormat::GetHeader(), SwFormatHeader::GetHeaderFormat(), SwFormatFrameSize::GetHeightSizeType(), SfxItemSet::GetItem(), SfxItemSet::GetItemIfSet(), SwPageDesc::GetLandscape(), SwPageDesc::GetMaster(), SwFormat::GetName(), SwPageDesc::GetName(), SvxNumberType::GetNumberingType(), SwPageDesc::GetNumType(), SfxItemSet::GetPool(), SwPageDesc::GetRegisterFormatColl(), SvxSizeItem::GetSize(), SwPageDesc::GetUseOn(), GetValue, SwFormatHeader::IsActive(), SwFormatFooter::IsActive(), SwPageDesc::IsFirstShared(), SwPageDesc::IsFooterShared(), SwPageDesc::IsHeaderShared(), lcl_convertUseToSvx(), MAXHEIGHT, MAXWIDTH, MIN_BORDER_DIST, SfxItemSet::Put(), RES_BACKGROUND_FULL_SIZE(), RES_FRMATR_BEGIN(), RES_FRMATR_END(), RES_RTL_GUTTER(), rSet, SvxPageItem::SetDescName(), SvxPageItem::SetLandscape(), SvxPageItem::SetNumType(), SvxPageItem::SetPageUsage(), CntUnencodedStringItem::SetValue(), SfxPoolItem::SetWhich(), XATTR_FILL_FIRST(), and XATTR_FILL_LAST().
Referenced by SwDocStyleSheet::GetItemSet(), and SwView::GetState().
SW_DLLPUBLIC void PrepareBoxInfo | ( | SfxItemSet & | rSet, |
const SwWrtShell & | rSh | ||
) |
Definition at line 82 of file uitool.cxx.
References SwCursorShell::GetCursor(), SwCursorShell::GetCursorCnt(), SfxItemSet::GetItemIfSet(), SwWrtShell::GetSelectionType(), SwCursorShell::IsTableMode(), MIN_BORDER_DIST, SfxItemSet::Put(), rSet, Table, and Text.
Referenced by SwEnvFormatPage::Edit(), SwBaseShell::ExecDlg(), SwTextShell::Execute(), SwBaseShell::GetBorderState(), sw_CharDialog(), SwFlyFrameAttrMgr::SwFlyFrameAttrMgr(), and SwFlyFrameAttrMgr::UpdateAttrMgr().
void SetApplyCharUnit | ( | bool | bApplyChar, |
bool | bWeb | ||
) |
Definition at line 878 of file uitool.cxx.
References SW_MOD.
Referenced by SwModule::ApplyItemSet().
void SetDfltMetric | ( | FieldUnit | eMetric, |
bool | bWeb | ||
) |
Definition at line 763 of file uitool.cxx.
References SW_MOD.
Referenced by SwModule::ApplyItemSet(), and SwModule::ExecOther().
void SfxToSwPageDescAttr | ( | const SwWrtShell & | rShell, |
SfxItemSet & | rSet | ||
) |
Definition at line 656 of file uitool.cxx.
References SfxItemSet::ClearItem(), SwEditShell::GetCurAttr(), SfxItemSet::GetItemIfSet(), SfxItemSet::GetItemState(), SfxShell::GetPool(), GetValue, SwWrtShell::GetView(), SfxItemSet::Put(), SwFormatPageDesc::RegisterToPageDesc(), RES_BREAK(), RES_PAGEDESC(), rSet, and SwFormatPageDesc::SetNumOffset().
Referenced by SwTextShell::ExecParaAttrArgs(), SwView::FUNC_Search(), IMPL_LINK_NOARG(), SwView::Replace(), and sw_ParagraphDialogResult().
void SwToSfxPageDescAttr | ( | SfxItemSet & | rSet | ) |
Definition at line 717 of file uitool.cxx.
References aName, SfxItemSet::ClearItem(), SfxItemSet::GetItemState(), SwPageDesc::GetName(), SwFormatPageDesc::GetNumOffset(), SwFormatPageDesc::GetPageDesc(), SfxItemSet::Put(), and RES_PAGEDESC().
Referenced by SwDocShell::Edit(), SwTextShell::Execute(), and SwTextShell::GetAttrState().