KDEUI
krichtextwidget.cpp
Go to the documentation of this file.
232 d->action_text_foreground_color = new KAction(KIcon("format-stroke-color"), i18nc("@action", "Text &Color..."), actionCollection);
236 connect(d->action_text_foreground_color, SIGNAL(triggered()), this, SLOT(_k_setTextForegroundColor()));
244 d->action_text_background_color = new KAction(KIcon("format-fill-color"), i18nc("@action", "Text &Highlight..."), actionCollection);
247 connect(d->action_text_background_color, SIGNAL(triggered()), this, SLOT(_k_setTextBackgroundColor()));
276 d->action_text_bold = new KToggleAction(KIcon("format-text-bold"), i18nc("@action boldify selected text", "&Bold"), actionCollection);
290 d->action_text_italic = new KToggleAction(KIcon("format-text-italic"), i18nc("@action italicize selected text", "&Italic"), actionCollection);
305 d->action_text_underline = new KToggleAction(KIcon("format-text-underline"), i18nc("@action underline selected text", "&Underline"), actionCollection);
320 d->action_text_strikeout = new KToggleAction(KIcon("format-text-strikethrough"), i18nc("@action", "&Strike Out"), actionCollection);
333 d->action_align_left = new KToggleAction(KIcon("format-justify-left"), i18nc("@action", "Align &Left"), actionCollection);
340 d->action_align_center = new KToggleAction(KIcon("format-justify-center"), i18nc("@action", "Align &Center"), actionCollection);
347 d->action_align_right = new KToggleAction(KIcon("format-justify-right"), i18nc("@action", "Align &Right"), actionCollection);
354 d->action_align_justify = new KToggleAction(KIcon("format-justify-fill"), i18nc("@action", "&Justify"), actionCollection);
380 d->action_direction_ltr = new KToggleAction(KIcon("format-text-direction-ltr"), i18nc("@action", "Left-to-Right"), actionCollection);
387 d->action_direction_rtl = new KToggleAction(KIcon("format-text-direction-rtl"), i18nc("@action", "Right-to-Left"), actionCollection);
406 d->action_list_style = new KSelectAction(KIcon("format-list-unordered"), i18nc("@title:menu", "List Style"), actionCollection);
433 d->action_list_indent = new KAction(KIcon("format-indent-more"), i18nc("@action", "Increase Indent"), actionCollection);
446 d->action_list_dedent = new KAction(KIcon("format-indent-less"), i18nc("@action", "Decrease Indent"), actionCollection);
459 d->action_insert_horizontal_rule = new KAction(KIcon("insert-horizontal-rule"), i18nc("@action", "Insert Rule Line"), actionCollection);
470 d->action_manage_link = new KAction(KIcon("insert-link"), i18nc("@action", "Link"), actionCollection);
481 d->action_format_painter = new KToggleAction(KIcon("draw-brush"), i18nc("@action", "Format Painter"), actionCollection);
492 d->action_to_plain_text = new KToggleAction(i18nc("@action", "To Plain Text"), actionCollection);
503 d->action_text_subscript = new KToggleAction(KIcon("format-text-subscript"), i18nc("@action", "Subscript"), actionCollection);
510 d->action_text_superscript = new KToggleAction(KIcon("format-text-superscript"), i18nc("@action", "Superscript"), actionCollection);
641 const int result = KColorDialog::getColor(currentTextForegroundColor, KColorScheme(QPalette::Active, KColorScheme::View).foreground().color() , q);
645 currentTextForegroundColor = KColorScheme(QPalette::Active, KColorScheme::View).foreground().color() ;
656 const int result = KColorDialog::getColor(currentTextBackgroundColor, KColorScheme(QPalette::Active, KColorScheme::View).foreground().color() , q);
660 currentTextBackgroundColor = KColorScheme(QPalette::Active, KColorScheme::View).foreground().color() ;
void alignCenter()
Sets the alignment of the current block to Centered.
Definition: krichtextedit.cpp:182
void setTextBold(bool bold)
Toggles the bold formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:225
void alignJustify()
Sets the alignment of the current block to Justified.
Definition: krichtextedit.cpp:196
void cursorPositionChanged()
Action to change the font family of the currently selected text.
Definition: krichtextwidget.h:103
void setTextStrikeOut(bool strikeOut)
Toggles the strikeout formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:252
bool underline() const
Action to convert the current text to a hyperlink.
Definition: krichtextwidget.h:193
Includes all above actions for full rich text support.
Definition: krichtextwidget.h:226
void setTextUnderline(bool underline)
Toggles the underline formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:243
void makeRightToLeft()
Sets the direction of the current block to Right-To-Left.
Definition: krichtextedit.cpp:203
void setFontSize(int size)
Sets the current word or selection to the font size size.
Definition: krichtextedit.cpp:288
void setUnderline(bool enable)
QFont font() const
Actions to align the current paragraph left, righ, center or justify.
Definition: krichtextwidget.h:179
QAction * addAction(const QString &name, QAction *action)
Add an action under the given name to the collection.
Definition: kactioncollection.cpp:217
Action to strike out the selected text.
Definition: krichtextwidget.h:93
QAction * addAction(QAction *action)
typedef Alignment
bool disconnect(const QObject *sender, const char *signal, const QObject *receiver, const char *method)
void alignRight()
Sets the alignment of the current block to Right Aligned.
Definition: krichtextedit.cpp:189
Action to increase the current list nesting level.
Definition: krichtextwidget.h:149
void setTextSubScript(bool subscript)
Toggles the subscript formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:331
void currentCharFormatChanged(const QTextCharFormat &f)
bool bold() const
QString i18nc(const char *ctxt, const char *text)
Actions to format text as superscript or subscript.
Definition: krichtextwidget.h:214
bool italic() const
Action to make the current line a list element, change the list style or remove list formatting...
Definition: krichtextwidget.h:143
QBrush background() const
const QColor & color() const
void setBold(bool enable)
Action to underline the selected text.
Definition: krichtextwidget.h:85
enabled
bool italic() const
QBrush foreground(ForegroundRole=NormalText) const
Retrieve the requested foreground brush.
Definition: kcolorscheme.cpp:459
Action to decrease the current list nesting level.
Definition: krichtextwidget.h:154
Action to make the mouse cursor a format painter.
Definition: krichtextwidget.h:200
virtual void mouseReleaseEvent(QMouseEvent *e)
Action to insert a horizontal line.
Definition: krichtextwidget.h:186
void setActionsEnabled(bool enabled)
Disables or enables all of the actions created by createActions().
Action to change direction of text to Right-To-Left or Left-To-Right.
Definition: krichtextwidget.h:221
void switchToPlainText()
This will switch the editor to plain text mode.
Definition: krichtextedit.cpp:306
bool underline() const
void setTextSuperScript(bool superscript)
Toggles the superscript formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:322
void updateActionStates()
Tells KRichTextWidget to update the state of the actions created by createActions().
void indentListMore()
Increases the nesting level of the current block or selected blocks.
Definition: krichtextedit.cpp:150
void removeAction(QAction *action)
Removes an action from the collection and deletes it.
Definition: kactioncollection.cpp:316
void setTextCursor(const QTextCursor &cursor)
void insertHorizontalRule()
Inserts a horizontal rule below the current block.
Definition: krichtextedit.cpp:161
void setShortcut(const QKeySequence &shortcut)
virtual void createActions(KActionCollection *actionCollection)
Creates the actions and adds them to the given action collection.
void setItalic(bool enable)
void makeLeftToRight()
Sets the direction of the current block to Left-To-Right.
Definition: krichtextedit.cpp:214
RichTextSupport richTextSupport() const
Returns the supported rich text subset available.
Action to change the text of the whole text edit to plain text.
Definition: krichtextwidget.h:206
Action to format the selected text as italic.
Definition: krichtextwidget.h:77
QString family() const
Action to format the selected text as bold.
Definition: krichtextwidget.h:69
QTextCharFormat currentCharFormat() const
VerticalAlignment verticalAlignment() const
The KRichTextEdit class provides a widget to edit and display rich text.
Definition: krichtextedit.h:65
Action to change the text color of the currently selected text.
Definition: krichtextwidget.h:120
void setRichTextSupport(const KRichTextWidget::RichTextSupport &support)
Sets the supported rich text subset available.
void setCharFormat(const QTextCharFormat &format)
static int getColor(QColor &theColor, QWidget *parent=0L)
Creates a modal color dialog, let the user choose a color, and returns when the dialog is closed...
Definition: kcolordialog.cpp:1492
bool strikeOut() const
void setFontFamily(const QString &fontFamily)
Sets the current word or selection to the font family fontFamily.
Definition: krichtextedit.cpp:279
bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
void alignLeft()
Sets the alignment of the current block to Left Aligned.
Definition: krichtextedit.cpp:175
QObject * parent() const
void indentListLess()
Decreases the nesting level of the current block or selected blocks.
Definition: krichtextedit.cpp:156
Action to change the background color of the currently selected text.
Definition: krichtextwidget.h:128
Action to change the font size of the currently selected text.
Definition: krichtextwidget.h:112
void setEnabled(bool)
int pointSize() const
QTextCursor textCursor() const
bool isValid() const
void setTextItalic(bool italic)
Toggles the italic formatting of the current word or selection at the current cursor position...
Definition: krichtextedit.cpp:234
bool bold() const
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:24:00 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:24:00 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.