]> git.lyx.org Git - lyx.git/commitdiff
strip out |++| nonsense
authorAngus Leeming <leeming@lyx.org>
Tue, 4 Mar 2003 18:54:56 +0000 (18:54 +0000)
committerAngus Leeming <leeming@lyx.org>
Tue, 4 Mar 2003 18:54:56 +0000 (18:54 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6341 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/ChangeLog
src/mathed/command_inset.C
src/mathed/command_inset.h

index b9fa3f9598ac18cbe459b6fc7a5add09a87d61c5..69bf59cb93cd8b27e59ce802b18d5fb0c72b0a7e 100644 (file)
@@ -2,6 +2,8 @@
 
        * command_inset.[Ch] (createDialogStr): a new function to generate
        something that the frontend Dialogs will understand.
+       (c-tor): the string passed to the c-tor is now understood to be
+       simply the inset's name, not some strange beast containing "|++|".
 
        * math_factory.[Ch] (createMathInset_fromDialogStr): new function
        parses the string passed from the frontends.
index f8a03c2e382e4f34962bbbb2434a3bbca9d1aa74..34956bcdff2c9d5fd5b9e15aaa38b23125567185 100644 (file)
@@ -5,20 +5,10 @@
 #include "Lsstream.h"
 
 
-CommandInset::CommandInset(string const & data)
+CommandInset::CommandInset(string const & name)
+       : name_(name)
 {
        lock_ = true;
-
-       string::size_type idx0 = data.find("|++|");
-       name_ = data.substr(0, idx0);
-       if (idx0 == string::npos)
-               return;
-       idx0 += 4;
-       string::size_type idx1 = data.find("|++|", idx0);
-       cell(0) = asArray(data.substr(idx0, idx1 - idx0));
-       if (idx1 == string::npos)
-               return;
-       cell(1) = asArray(data.substr(idx1 + 4));
 }
 
 
index 9902afc811db166d943eace60c3888f5a3f2832f..d8264067d7063c7de09de3b6957bc907c759ba9e 100644 (file)
@@ -20,8 +20,8 @@
 /// Inset for things like \name[options]{contents}
 class CommandInset : public ButtonInset {
 public:
-       /// name, contents, options deliminited by '|++|'
-       explicit CommandInset(string const & data);
+       ///
+       explicit CommandInset(string const & name);
        ///
        MathInset * clone() const;
        ///