LFUN_FONT_FREE_* -> LFUN_TEXSTYLE_*

http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg141274.html


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25225 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Pavel Sanda 2008-06-11 08:35:15 +00:00
parent d708dfe1fd
commit 07113cf424
9 changed files with 25 additions and 23 deletions

View File

@ -254,7 +254,7 @@ Menuset
OptItem "Move Section down|d" "outline-down" OptItem "Move Section down|d" "outline-down"
OptItem "Move Section up|u" "outline-up" OptItem "Move Section up|u" "outline-up"
Separator Separator
Item "Apply Last Text Style|A" "font-free-apply" Item "Apply Last Text Style|A" "textstyle-apply"
Submenu "Text Style|S" "edit_textstyles" Submenu "Text Style|S" "edit_textstyles"
Item "Paragraph Settings...|P" "layout-paragraph" Item "Paragraph Settings...|P" "layout-paragraph"
Separator Separator

View File

@ -70,7 +70,7 @@ ToolbarSet
Separator Separator
Item "Toggle emphasis" "font-emph" Item "Toggle emphasis" "font-emph"
Item "Toggle noun" "font-noun" Item "Toggle noun" "font-noun"
Item "Apply last" "font-free-apply" Item "Apply last" "textstyle-apply"
Separator Separator
Item "Insert math" "math-mode" Item "Insert math" "math-mode"
Item "Insert graphics" "dialog-show-new-inset graphics" Item "Insert graphics" "dialog-show-new-inset graphics"

View File

@ -55,8 +55,8 @@ enum FuncCode
LFUN_INSET_TOGGLE, LFUN_INSET_TOGGLE,
// 20 // 20
LFUN_HFILL_INSERT, LFUN_HFILL_INSERT,
LFUN_FONT_FREE_APPLY, LFUN_TEXTSTYLE_APPLY,
LFUN_FONT_FREE_UPDATE, LFUN_TEXTSTYLE_UPDATE,
LFUN_FONT_EMPH, LFUN_FONT_EMPH,
LFUN_FONT_BOLD, LFUN_FONT_BOLD,
// 25 // 25

View File

@ -1145,17 +1145,19 @@ void LyXAction::init()
*/ */
{ LFUN_FONT_SIZE, "font-size", Noop, Layout }, { LFUN_FONT_SIZE, "font-size", Noop, Layout },
/*! /*!
* \var lyx::FuncCode lyx::LFUN_FONT_FREE_APPLY * \var lyx::FuncCode lyx::LFUN_TEXTSTYLE_APPLY
* \li Action: Toggle user-defined text style. * \li Action: Toggle user-defined (=last-time used) text style.
* \li Syntax: font-free-apply * \li Notion: This style is set via #LFUN_TEXTSTYLE_UPDATE, which is
automatically trigerred when using Text Style dialog.
* \li Syntax: textstyle-apply
* \li Origin: leeming, 12 Mar 2003 * \li Origin: leeming, 12 Mar 2003
* \endvar * \endvar
*/ */
{ LFUN_FONT_FREE_APPLY, "font-free-apply", Noop, Layout }, { LFUN_TEXTSTYLE_APPLY, "textstyle-apply", Noop, Layout },
/*! /*!
* \var lyx::FuncCode lyx::LFUN_FONT_FREE_UPDATE * \var lyx::FuncCode lyx::LFUN_TEXTSTYLE_UPDATE
* \li Action: Update and apply user-defined text style. * \li Action: Apply text style and update the settings to be used by #LFUN_TEXTSTYLE_APPLY.
* \li Syntax: font-free-update <FONT_INFO> * \li Syntax: textstyle-update <FONT_INFO>
* \li Params: <FONT_INFO>: specifies font atributes, e.g. family, series, shape, * \li Params: <FONT_INFO>: specifies font atributes, e.g. family, series, shape,
size, emph, noun, underbar, number, color, language, size, emph, noun, underbar, number, color, language,
toggleall.\n toggleall.\n
@ -1164,7 +1166,7 @@ void LyXAction::init()
* \li Origin: leeming, 12 Mar 2003 * \li Origin: leeming, 12 Mar 2003
* \endvar * \endvar
*/ */
{ LFUN_FONT_FREE_UPDATE, "font-free-update", Noop, Layout }, { LFUN_TEXTSTYLE_UPDATE, "textstyle-update", Noop, Layout },
/*! /*!
* \var lyx::FuncCode lyx::LFUN_SCREEN_FONT_UPDATE * \var lyx::FuncCode lyx::LFUN_SCREEN_FONT_UPDATE
* \li Action: Update fonts and its metrics. * \li Action: Update fonts and its metrics.

View File

@ -1583,14 +1583,14 @@ void Text::dispatch(Cursor & cur, FuncRequest & cmd)
break; break;
} }
case LFUN_FONT_FREE_APPLY: case LFUN_TEXTSTYLE_APPLY:
toggleAndShow(cur, this, freefont, toggleall); toggleAndShow(cur, this, freefont, toggleall);
cur.message(_("Character set")); cur.message(_("Character set"));
break; break;
// Set the freefont using the contents of \param data dispatched from // Set the freefont using the contents of \param data dispatched from
// the frontends and apply it at the current cursor location. // the frontends and apply it at the current cursor location.
case LFUN_FONT_FREE_UPDATE: { case LFUN_TEXTSTYLE_UPDATE: {
Font font; Font font;
bool toggle; bool toggle;
if (font.fromString(to_utf8(cmd.argument()), toggle)) { if (font.fromString(to_utf8(cmd.argument()), toggle)) {
@ -2207,8 +2207,8 @@ bool Text::getStatus(Cursor & cur, FuncRequest const & cmd,
case LFUN_FONT_UNDERLINE: case LFUN_FONT_UNDERLINE:
case LFUN_FONT_SIZE: case LFUN_FONT_SIZE:
case LFUN_LANGUAGE: case LFUN_LANGUAGE:
case LFUN_FONT_FREE_APPLY: case LFUN_TEXTSTYLE_APPLY:
case LFUN_FONT_FREE_UPDATE: case LFUN_TEXTSTYLE_UPDATE:
case LFUN_LAYOUT_PARAGRAPH: case LFUN_LAYOUT_PARAGRAPH:
case LFUN_PARAGRAPH_UPDATE: case LFUN_PARAGRAPH_UPDATE:
case LFUN_ACCENT_UMLAUT: case LFUN_ACCENT_UMLAUT:

View File

@ -68,7 +68,7 @@ private:
void clearParams() {} void clearParams() {}
void dispatchParams(); void dispatchParams();
bool isBufferDependent() const { return true; } bool isBufferDependent() const { return true; }
FuncCode getLfun() const { return LFUN_FONT_FREE_UPDATE; } FuncCode getLfun() const { return LFUN_TEXTSTYLE_UPDATE; }
void saveSession() const; void saveSession() const;
void restoreSession(); void restoreSession();
//@} //@}

View File

@ -665,8 +665,8 @@ bool InsetCollapsable::getStatus(Cursor & cur, FuncRequest const & cmd,
case LFUN_FONT_TYPEWRITER: case LFUN_FONT_TYPEWRITER:
case LFUN_FONT_DEFAULT: case LFUN_FONT_DEFAULT:
case LFUN_FONT_EMPH: case LFUN_FONT_EMPH:
case LFUN_FONT_FREE_APPLY: case LFUN_TEXTSTYLE_APPLY:
case LFUN_FONT_FREE_UPDATE: case LFUN_TEXTSTYLE_UPDATE:
case LFUN_FONT_NOUN: case LFUN_FONT_NOUN:
case LFUN_FONT_ROMAN: case LFUN_FONT_ROMAN:
case LFUN_FONT_SANS: case LFUN_FONT_SANS:

View File

@ -3456,8 +3456,8 @@ void InsetTabular::doDispatch(Cursor & cur, FuncRequest & cmd)
case LFUN_FONT_FRAK: case LFUN_FONT_FRAK:
case LFUN_FONT_TYPEWRITER: case LFUN_FONT_TYPEWRITER:
case LFUN_FONT_SANS: case LFUN_FONT_SANS:
case LFUN_FONT_FREE_APPLY: case LFUN_TEXTSTYLE_APPLY:
case LFUN_FONT_FREE_UPDATE: case LFUN_TEXTSTYLE_UPDATE:
case LFUN_FONT_SIZE: case LFUN_FONT_SIZE:
case LFUN_FONT_UNDERLINE: case LFUN_FONT_UNDERLINE:
case LFUN_LANGUAGE: case LFUN_LANGUAGE:

View File

@ -880,8 +880,8 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd)
break; break;
// Math fonts // Math fonts
case LFUN_FONT_FREE_APPLY: case LFUN_TEXTSTYLE_APPLY:
case LFUN_FONT_FREE_UPDATE: case LFUN_TEXTSTYLE_UPDATE:
handleFont2(cur, cmd.argument()); handleFont2(cur, cmd.argument());
break; break;