LibreOffice Module sw (master) 1
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
SwSpellPopup Class Reference

#include <olmenu.hxx>

Collaboration diagram for SwSpellPopup:
[legend]

Public Member Functions

 SwSpellPopup (SwWrtShell *pWrtSh, css::uno::Reference< css::linguistic2::XSpellAlternatives > xAlt, const OUString &rParaText)
 
 SwSpellPopup (SwWrtShell *pWrtSh, const css::linguistic2::ProofreadingResult &rResult, sal_Int32 nErrorInResult, const css::uno::Sequence< OUString > &rSuggestions, const OUString &rParaText)
 
 ~SwSpellPopup ()
 
void InitItemCommands (const css::uno::Sequence< OUString > &aSuggestions)
 
PopupMenuGetMenu ()
 
rtl::Reference< VCLXPopupMenuCreateMenuInterface ()
 
void Execute (const tools::Rectangle &rPopupPos, vcl::Window *pWin)
 
void Execute (sal_uInt16 nId)
 

Private Member Functions

void checkRedline ()
 Checks if any of the redline menu items should be hidden. More...
 

Static Private Member Functions

static void fillLangPopupMenu (PopupMenu *pPopupMenu, sal_uInt16 nLangStart, const css::uno::Sequence< OUString > &aSeq, SwWrtShell *pWrtSh, std::map< sal_Int16, OUString > &rLangTable)
 

Private Attributes

VclBuilder m_aBuilder
 
VclPtr< PopupMenum_xPopupMenu
 
sal_uInt16 m_nIgnoreWordId
 
sal_uInt16 m_nAddMenuId
 
sal_uInt16 m_nAddId
 
sal_uInt16 m_nSpellDialogId
 
sal_uInt16 m_nCorrectMenuId
 
sal_uInt16 m_nCorrectDialogId
 
sal_uInt16 m_nLangSelectionMenuId
 
sal_uInt16 m_nLangParaMenuId
 
sal_uInt16 m_nRedlineAcceptId
 
sal_uInt16 m_nRedlineRejectId
 
sal_uInt16 m_nRedlineNextId
 
sal_uInt16 m_nRedlinePrevId
 
SwWrtShellm_pSh
 
css::uno::Sequence< css::uno::Reference< css::linguistic2::XDictionary > > m_aDics
 
css::uno::Reference< css::linguistic2::XSpellAlternatives > m_xSpellAlt
 
OUString m_sExplanationLink
 
LanguageType m_nCheckedLanguage
 
std::map< sal_Int16, OUString > m_aLangTable_Text
 
std::map< sal_Int16, OUString > m_aLangTable_Paragraph
 
OUString m_aDicNameSingle
 
bool m_bGrammarResults
 

Detailed Description

Definition at line 76 of file olmenu.hxx.

Constructor & Destructor Documentation

◆ SwSpellPopup() [1/2]

SwSpellPopup::SwSpellPopup ( SwWrtShell pWrtSh,
css::uno::Reference< css::linguistic2::XSpellAlternatives >  xAlt,
const OUString &  rParaText 
)

◆ SwSpellPopup() [2/2]

SwSpellPopup::SwSpellPopup ( SwWrtShell pWrtSh,
const css::linguistic2::ProofreadingResult &  rResult,
sal_Int32  nErrorInResult,
const css::uno::Sequence< OUString > &  rSuggestions,
const OUString &  rParaText 
)

◆ ~SwSpellPopup()

SwSpellPopup::~SwSpellPopup ( )

Definition at line 566 of file olmenu.cxx.

Member Function Documentation

◆ checkRedline()

void SwSpellPopup::checkRedline ( )
private

◆ CreateMenuInterface()

rtl::Reference< VCLXPopupMenu > SwSpellPopup::CreateMenuInterface ( )
inline

Definition at line 133 of file olmenu.hxx.

◆ Execute() [1/2]

void SwSpellPopup::Execute ( const tools::Rectangle rPopupPos,
vcl::Window pWin 
)

Definition at line 666 of file olmenu.cxx.

References Execute(), vcl::Window::LogicToPixel(), and m_xPopupMenu.

Referenced by Execute().

◆ Execute() [2/2]

void SwSpellPopup::Execute ( sal_uInt16  nId)

Definition at line 672 of file olmenu.cxx.

References linguistic::AddEntryToDic(), SwRewriter::AddRule(), Chars, Application::CreateMessageDialog(), SwCursorShell::EndAction(), SwEditShell::EndUndo(), SwWrtShell::EnterStdMode(), Execute(), SfxDispatcher::Execute(), SwView::Execute(), SfxDispatcher::ExecuteList(), FN_REDLINE_ACCEPT_DIRECT, FN_REDLINE_NEXT_CHANGE, FN_REDLINE_PREV_CHANGE, FN_REDLINE_REJECT_DIRECT, FN_SPELL_GRAMMAR_DIALOG, SvxAutoCorrCfg::Get(), SvxAutoCorrCfg::GetAutoCorrect(), SwCursorShell::GetCursorDescr(), LinguMgr::GetDictionaryList(), SfxViewFrame::GetDispatcher(), SfxViewShell::GetFrameWeld(), Menu::GetItemText(), SwWrtShell::GetView(), SfxViewShell::GetViewFrame(), SwWrtShell::IsInsMode(), SwWrtShell::Left(), m_aDicNameSingle, m_aLangTable_Paragraph, m_aLangTable_Text, m_bGrammarResults, m_nAddId, m_nAddMenuId, m_nCheckedLanguage, m_nCorrectDialogId, m_nCorrectMenuId, m_nIgnoreWordId, m_nRedlineAcceptId, m_nRedlineNextId, m_nRedlinePrevId, m_nRedlineRejectId, m_nSpellDialogId, m_pSh, m_sExplanationLink, m_xPopupMenu, m_xSpellAlt, MN_AUTOCORR_END, MN_AUTOCORR_START, MN_DICTIONARIES_END, MN_DICTIONARIES_START, MN_EXPLANATION_LINK, MN_IGNORE_SELECTION, MN_SET_LANGUAGE_PARAGRAPH_END, MN_SET_LANGUAGE_PARAGRAPH_START, MN_SET_LANGUAGE_SELECTION_END, MN_SET_LANGUAGE_SELECTION_START, MN_SET_PARA_MORE, MN_SET_PARA_NONE, MN_SET_PARA_RESET, MN_SET_SELECTION_MORE, MN_SET_SELECTION_NONE, MN_SET_SELECTION_RESET, MN_SHORT_COMMENT, MN_SUGGESTION_END, MN_SUGGESTION_START, nId, linguistic::NONE, SvxAutoCorrect::PutText(), SwEditShell::Replace(), SwWrtShell::SetInsMode(), SwCursorShell::StartAction(), SwEditShell::StartUndo(), SvxDicError(), SvxPrepareAutoCorrect(), SwResId(), UI_REPLACE, UndoArg1, UndoArg2, and UndoArg3.

◆ fillLangPopupMenu()

void SwSpellPopup::fillLangPopupMenu ( PopupMenu pPopupMenu,
sal_uInt16  nLangStart,
const css::uno::Sequence< OUString > &  aSeq,
SwWrtShell pWrtSh,
std::map< sal_Int16, OUString > &  rLangTable 
)
staticprivate

◆ GetMenu()

PopupMenu & SwSpellPopup::GetMenu ( )
inline

Definition at line 128 of file olmenu.hxx.

◆ InitItemCommands()

void SwSpellPopup::InitItemCommands ( const css::uno::Sequence< OUString > &  aSuggestions)

Member Data Documentation

◆ m_aBuilder

VclBuilder SwSpellPopup::m_aBuilder
private

Definition at line 78 of file olmenu.hxx.

◆ m_aDicNameSingle

OUString SwSpellPopup::m_aDicNameSingle
private

Definition at line 103 of file olmenu.hxx.

Referenced by Execute().

◆ m_aDics

css::uno::Sequence< css::uno::Reference< css::linguistic2::XDictionary > > SwSpellPopup::m_aDics
private

Definition at line 93 of file olmenu.hxx.

◆ m_aLangTable_Paragraph

std::map< sal_Int16, OUString > SwSpellPopup::m_aLangTable_Paragraph
private

Definition at line 101 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().

◆ m_aLangTable_Text

std::map< sal_Int16, OUString > SwSpellPopup::m_aLangTable_Text
private

Definition at line 100 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().

◆ m_bGrammarResults

bool SwSpellPopup::m_bGrammarResults
private

Definition at line 104 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().

◆ m_nAddId

sal_uInt16 SwSpellPopup::m_nAddId
private

Definition at line 82 of file olmenu.hxx.

Referenced by Execute().

◆ m_nAddMenuId

sal_uInt16 SwSpellPopup::m_nAddMenuId
private

Definition at line 81 of file olmenu.hxx.

Referenced by Execute().

◆ m_nCheckedLanguage

LanguageType SwSpellPopup::m_nCheckedLanguage
private

Definition at line 98 of file olmenu.hxx.

Referenced by Execute().

◆ m_nCorrectDialogId

sal_uInt16 SwSpellPopup::m_nCorrectDialogId
private

Definition at line 85 of file olmenu.hxx.

Referenced by Execute().

◆ m_nCorrectMenuId

sal_uInt16 SwSpellPopup::m_nCorrectMenuId
private

Definition at line 84 of file olmenu.hxx.

Referenced by Execute().

◆ m_nIgnoreWordId

sal_uInt16 SwSpellPopup::m_nIgnoreWordId
private

Definition at line 80 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().

◆ m_nLangParaMenuId

sal_uInt16 SwSpellPopup::m_nLangParaMenuId
private

Definition at line 87 of file olmenu.hxx.

Referenced by InitItemCommands().

◆ m_nLangSelectionMenuId

sal_uInt16 SwSpellPopup::m_nLangSelectionMenuId
private

Definition at line 86 of file olmenu.hxx.

Referenced by InitItemCommands().

◆ m_nRedlineAcceptId

sal_uInt16 SwSpellPopup::m_nRedlineAcceptId
private

Definition at line 88 of file olmenu.hxx.

Referenced by checkRedline(), and Execute().

◆ m_nRedlineNextId

sal_uInt16 SwSpellPopup::m_nRedlineNextId
private

Definition at line 90 of file olmenu.hxx.

Referenced by checkRedline(), and Execute().

◆ m_nRedlinePrevId

sal_uInt16 SwSpellPopup::m_nRedlinePrevId
private

Definition at line 91 of file olmenu.hxx.

Referenced by checkRedline(), and Execute().

◆ m_nRedlineRejectId

sal_uInt16 SwSpellPopup::m_nRedlineRejectId
private

Definition at line 89 of file olmenu.hxx.

Referenced by checkRedline(), and Execute().

◆ m_nSpellDialogId

sal_uInt16 SwSpellPopup::m_nSpellDialogId
private

Definition at line 83 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().

◆ m_pSh

SwWrtShell* SwSpellPopup::m_pSh
private

Definition at line 92 of file olmenu.hxx.

Referenced by checkRedline(), and Execute().

◆ m_sExplanationLink

OUString SwSpellPopup::m_sExplanationLink
private

Definition at line 96 of file olmenu.hxx.

Referenced by Execute().

◆ m_xPopupMenu

VclPtr<PopupMenu> SwSpellPopup::m_xPopupMenu
private

Definition at line 79 of file olmenu.hxx.

Referenced by checkRedline(), Execute(), and InitItemCommands().

◆ m_xSpellAlt

css::uno::Reference< css::linguistic2::XSpellAlternatives > SwSpellPopup::m_xSpellAlt
private

Definition at line 94 of file olmenu.hxx.

Referenced by Execute(), and InitItemCommands().


The documentation for this class was generated from the following files: