From 5cecfe8c7f3bc164f000ea42348bf6b22ea2227f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Fri, 8 Feb 2002 09:42:59 +0000 Subject: [PATCH] popup math panel on right mouse click support for \dddot git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@3508 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/mathed/ChangeLog | 6 ++++++ src/mathed/formulabase.C | 5 +++++ src/mathed/math_decorationinset.C | 7 +------ src/mathed/math_hash.C | 1 + src/mathed/math_support.C | 13 +++++++++++-- 5 files changed, 24 insertions(+), 8 deletions(-) diff --git a/src/mathed/ChangeLog b/src/mathed/ChangeLog index a29e67766f..71840dee64 100644 --- a/src/mathed/ChangeLog +++ b/src/mathed/ChangeLog @@ -1,4 +1,8 @@ +2002-02-08 André Pönitz + + * math_support.[Ch]: some support for \dddot + 2002-02-08 Otto Tronarp * math_decorationinset.C: @@ -10,6 +14,8 @@ 2002-02-08 Martin Vermeer * formulabase.C (localDispatch): fix umlaut handling + + * formulabase.C: pop up math panel on right mouse click 2002-02-01 André Pönitz diff --git a/src/mathed/formulabase.C b/src/mathed/formulabase.C index 276200e3b9..c5ef86ec70 100644 --- a/src/mathed/formulabase.C +++ b/src/mathed/formulabase.C @@ -47,6 +47,7 @@ #include "math_pos.h" #include "math_spaceinset.h" #include "undo_funcs.h" +#include "frontends/Dialogs.h" #include "intl.h" using std::endl; @@ -328,6 +329,10 @@ void InsetFormulaBase::insetButtonPress(BufferView * bv, } break; */ + case 3: + // launch math panel for right mouse button + bv->owner()->getDialogs()->showMathPanel(); + break; } bv->updateInset(this, false); } diff --git a/src/mathed/math_decorationinset.C b/src/mathed/math_decorationinset.C index 267b5e6ead..2bdfc6276f 100644 --- a/src/mathed/math_decorationinset.C +++ b/src/mathed/math_decorationinset.C @@ -24,12 +24,7 @@ MathInset * MathDecorationInset::clone() const bool MathDecorationInset::upper() const { - return - name_ != "underbar" && - name_ != "underline" && - name_ != "underbrace" && - name_ != "underleftarrow" && - name_ != "underrightarrow"; + return name_.substr(0, 5) != "under"; } diff --git a/src/mathed/math_hash.C b/src/mathed/math_hash.C index edf63d142e..af928434ff 100644 --- a/src/mathed/math_hash.C +++ b/src/mathed/math_hash.C @@ -64,6 +64,7 @@ key_type wordlist_array[] = {"coth", LM_TK_FUNC, 0}, {"csc", LM_TK_FUNC, 0}, {"ddot", LM_TK_DECORATION, 0}, + {"dddot", LM_TK_DECORATION, 0}, {"ddots", LM_TK_DOTS, 0}, {"deg", LM_TK_FUNC, 0}, {"det", LM_TK_FUNCLIM, 0}, diff --git a/src/mathed/math_support.C b/src/mathed/math_support.C index 542a3c8df6..45facff9de 100644 --- a/src/mathed/math_support.C +++ b/src/mathed/math_support.C @@ -394,13 +394,21 @@ double const hline[] = { }; -double const hline2[] = { +double const ddot[] = { 1, 0.2, 0.5, 0.3, 0.5, 1, 0.7, 0.5, 0.8, 0.5, 0 }; +double const dddot[] = { + 1, 0.1, 0.5, 0.2, 0.5, + 1, 0.45, 0.5, 0.55, 0.5, + 1, 0.8, 0.5, 0.9, 0.5, + 0 +}; + + double const hline3[] = { 1, 0.1, 0, 0.15, 0, 1, 0.475, 0, 0.525, 0, @@ -496,7 +504,8 @@ named_deco_struct deco_table[] = { {"Updownarrow", Udarrow, 0 }, // Accents - {"ddot", hline2, 0 }, + {"ddot", ddot, 0 }, + {"dddot", dddot, 0 }, {"hat", angle, 3 }, {"grave", slash, 1 }, {"acute", slash, 0 }, -- 2.39.2