bool paste_internally = false;
if (button == 2
&& bv_->text->selection.set()) {
- owner_->getLyXFunc()->Dispatch(LFUN_COPY);
+ owner_->getLyXFunc()->dispatch(LFUN_COPY);
paste_internally = true;
}
// insert this
if (button == 2) {
if (paste_internally)
- owner_->getLyXFunc()->Dispatch(LFUN_PASTE);
+ owner_->getLyXFunc()->dispatch(LFUN_PASTE);
else
- owner_->getLyXFunc()->Dispatch(LFUN_PASTESELECTION,
+ owner_->getLyXFunc()->dispatch(LFUN_PASTESELECTION,
"paragraph");
selection_possible = false;
return;
+2001-07-12 Lars Gullik Bjønnes <larsbj@birdstep.com>
+
+ * lyxfunc.h: change more methods to begin with lower char.
+
2001-07-16 Dekel Tsur <dekelts@tau.ac.il>
* buffer.C (parseSingleLyXformat2Token): Generate error insets
if (lfun) {
ostringstream str;
str << _("LaTeX run number") << ' ' << count;
- lfun->Dispatch(LFUN_MESSAGE, str.str().c_str());
+ lfun->dispatch(LFUN_MESSAGE, str.str().c_str());
}
if (head.haschanged(OnlyFilename(ChangeExtension(file, ".idx")))) {
// no checks for now
lyxerr[Debug::LATEX] << "Running MakeIndex." << endl;
- if (lfun) lfun->Dispatch(LFUN_MESSAGE, _("Running MakeIndex."));
+ if (lfun) lfun->dispatch(LFUN_MESSAGE, _("Running MakeIndex."));
// WriteStatus(minib, _("Running MakeIndex."));
rerun = runMakeIndex(OnlyFilename(ChangeExtension(file, ".idx")));
}
// tags is found -> run bibtex and set rerun = true;
// no checks for now
lyxerr[Debug::LATEX] << "Running BibTeX." << endl;
- if (lfun) lfun->Dispatch(LFUN_MESSAGE, _("Running BibTeX."));
+ if (lfun) lfun->dispatch(LFUN_MESSAGE, _("Running BibTeX."));
//WriteStatus(minib, _("Running BibTeX."));
updateBibtexDependencies(head, bibtex_info);
rerun |= runBibTeX(bibtex_info);
if (lfun) {
ostringstream str;
str << _("LaTeX run number") << ' ' << count;
- lfun->Dispatch(LFUN_MESSAGE, str.str().c_str());
+ lfun->dispatch(LFUN_MESSAGE, str.str().c_str());
}
// WriteStatus(minib,
if (head.haschanged(OnlyFilename(ChangeExtension(file, ".idx")))) {
// no checks for now
lyxerr[Debug::LATEX] << "Running MakeIndex." << endl;
- if (lfun) lfun->Dispatch(LFUN_MESSAGE, _("Running MakeIndex."));
+ if (lfun) lfun->dispatch(LFUN_MESSAGE, _("Running MakeIndex."));
//WriteStatus(minib, _("Running MakeIndex."));
rerun = runMakeIndex(OnlyFilename(ChangeExtension(file, ".idx")));
}
if (lfun) {
ostringstream str;
str << _("LaTeX run number") << ' ' << count;
- lfun->Dispatch(LFUN_MESSAGE, str.str().c_str());
+ lfun->dispatch(LFUN_MESSAGE, str.str().c_str());
}
// WriteStatus(minib, string(_("LaTeX run number ")) + tostr(count));
void ControlCommand::applyParamsNoInset()
{
if (action_ == LFUN_NOACTION) return;
- lv_.getLyXFunc()->Dispatch(action_, params().getAsString());
+ lv_.getLyXFunc()->dispatch(action_, params().getAsString());
}
void ControlRef::gotoRef(string const & ref) const
{
- lv_.getLyXFunc()->Dispatch(LFUN_BOOKMARK_SAVE, "0");
- lv_.getLyXFunc()->Dispatch(LFUN_REF_GOTO, ref);
+ lv_.getLyXFunc()->dispatch(LFUN_BOOKMARK_SAVE, "0");
+ lv_.getLyXFunc()->dispatch(LFUN_REF_GOTO, ref);
}
void ControlRef::gotoBookmark() const
{
- lv_.getLyXFunc()->Dispatch(LFUN_BOOKMARK_GOTO, "0");
+ lv_.getLyXFunc()->dispatch(LFUN_BOOKMARK_GOTO, "0");
}
string const val(tostr(params().first) + " " + tostr(params().second));
- lv_.getLyXFunc()->Dispatch(LFUN_INSET_TABULAR, val);
+ lv_.getLyXFunc()->dispatch(LFUN_INSET_TABULAR, val);
}
void ControlToc::Goto(int const & id) const
{
string const tmp = tostr(id);
- lv_.getLyXFunc()->Dispatch(LFUN_GOTO_PARAGRAPH, tmp);
+ lv_.getLyXFunc()->dispatch(LFUN_GOTO_PARAGRAPH, tmp);
}
ostringstream ost;
ost << delim_values[left] << ' ' << delim_values[right];
- lv_->getLyXFunc()->Dispatch(LFUN_MATH_DELIM, ost.str().c_str());
+ lv_->getLyXFunc()->dispatch(LFUN_MATH_DELIM, ost.str().c_str());
}
bool FormMathsDelim::input(FL_OBJECT *, long)
ostringstream ost;
ost << nx << ' ' << ny << ' ' << c << sh;
- lv_->getLyXFunc()->Dispatch(LFUN_INSERT_MATRIX, ost.str().c_str());
+ lv_->getLyXFunc()->dispatch(LFUN_INSERT_MATRIX, ost.str().c_str());
}
bool FormMathsMatrix::input(FL_OBJECT * ob, long)
void FormMathsPanel::insertSymbol(string const & sym) const
{
- lv_->getLyXFunc()->Dispatch(LFUN_INSERT_MATH, sym);
+ lv_->getLyXFunc()->dispatch(LFUN_INSERT_MATH, sym);
}
void FormMathsPanel::mathDisplay() const
{
- lv_->getLyXFunc()->Dispatch(LFUN_MATH_DISPLAY);
+ lv_->getLyXFunc()->dispatch(LFUN_MATH_DISPLAY);
}
colors_.modifiedXformsPrefs = !XformsColor::write(filename);
}
- lv_->getLyXFunc()->Dispatch(LFUN_SAVEPREFERENCES);
+ lv_->getLyXFunc()->dispatch(LFUN_SAVEPREFERENCES);
}
string const s = lcolor.getLyXName(lc) + string(" ") +
hexname;
- parent_.lv_->getLyXFunc()->Dispatch(LFUN_SET_COLOR, s);
+ parent_.lv_->getLyXFunc()->dispatch(LFUN_SET_COLOR, s);
}
}
}
string const arg = lcolor.getLyXName(lc) + " black";
parent_.lv_->getLyXFunc()->
- Dispatch(LFUN_SET_COLOR, arg);
+ dispatch(LFUN_SET_COLOR, arg);
continue;
}
if (changed) {
// Now update the buffers
// Can anything below here affect the redraw process?
- parent_.lv_->getLyXFunc()->Dispatch(LFUN_SCREEN_FONT_UPDATE);
+ parent_.lv_->getLyXFunc()->dispatch(LFUN_SCREEN_FONT_UPDATE);
}
}
// If the action value is too low, then it is not a
// valid action, but something else.
if (choice >= action_offset + 1) {
- view->getLyXFunc()->Dispatch(choice - action_offset);
- }
- else {
+ view->getLyXFunc()->dispatch(choice - action_offset);
+ } else {
lyxerr[Debug::GUI]
<< "MenuCallback: ignoring bogus action "
<< choice << endl;
}
- }
- else
+ } else {
lyxerr << "Error in MenuCallback" << endl;
+ }
std::for_each(submenus.begin(), submenus.end(), fl_freepup);
// restore tabstop length
void Toolbar::Pimpl::layoutSelected(int sel)
{
string const tmp = tostr(sel);
- owner->getLyXFunc()->Dispatch(LFUN_LAYOUTNO, tmp);
+ owner->getLyXFunc()->dispatch(LFUN_LAYOUTNO, tmp);
}
{
XFormsView * owner = static_cast<XFormsView *>(ob->u_vdata);
- string res = owner->getLyXFunc()->Dispatch(int(ac));
+ string res = owner->getLyXFunc()->dispatch(int(ac));
if (!res.empty())
lyxerr[Debug::GUI] << "ToolbarCB: Function returned: "
<< res << endl;
: ChangeExtension(filename,
formats.Extension(loader_format));
InsertAsciiFile(lv->view(), filename2, as_paragraphs);
- lv->getLyXFunc()->Dispatch(LFUN_MARK_OFF);
+ lv->getLyXFunc()->dispatch(LFUN_MARK_OFF);
}
// we are done
+2001-07-16 Lars Gullik Bjønnes <larsbj@birdstep.com>
+
+ * insetert.C (latex): write out all paragraphs.
+
2001-07-17 Baruch Even <baruch@lyx.org>
* insetgraphics.C (draw): Removed unneeded casts.
int InsetERT::latex(Buffer const *, std::ostream & os, bool /*fragile*/,
bool /*free_spc*/) const
{
- Paragraph::size_type siz = inset.paragraph()->size();
- for (Paragraph::size_type i = 0; i != siz; ++i) {
- char c = inset.paragraph()->getChar(i);
- switch (c) {
- case Paragraph::META_NEWLINE:
- os << '\n';
- break;
- default:
- os << c;
- break;
+ Paragraph * par = inset.paragraph();
+ while (par) {
+ Paragraph::size_type siz = inset.paragraph()->size();
+ for (Paragraph::size_type i = 0; i != siz; ++i) {
+ char c = inset.paragraph()->getChar(i);
+ switch (c) {
+ case Paragraph::META_NEWLINE:
+ os << '\n';
+ break;
+ default:
+ os << c;
+ break;
+ }
}
+ par = par->next();
}
+
return 1;
}
void InsetParent::edit(BufferView * bv, int, int, unsigned int)
{
bv->owner()->getLyXFunc()->
- Dispatch(LFUN_CHILDOPEN, getContents());
+ dispatch(LFUN_CHILDOPEN, getContents());
}
// Eventually trigger dialog with button 3 not 1
if (button == 3 )
bv->owner()->getLyXFunc()->
- Dispatch(LFUN_REF_GOTO, getContents());
+ dispatch(LFUN_REF_GOTO, getContents());
else if (button == 1 )
bv->owner()->getDialogs()->showRef( this );
}
// see if we found the layout number:
if (!layout.first) {
string const msg = string(N_("Layout ")) + arg + N_(" not known");
- bv->owner()->getLyXFunc()->Dispatch(LFUN_MESSAGE, msg);
+ bv->owner()->getLyXFunc()->dispatch(LFUN_MESSAGE, msg);
break;
}
// otherwise, let the GUI handle the batch command
lyxGUI->regBuf(last_loaded);
- lyxGUI->getLyXView()->getLyXFunc()->Dispatch(batch_command);
+ lyxGUI->getLyXView()->getLyXFunc()->dispatch(batch_command);
// fall through...
}
bool tmp_sc = show_sc;
show_sc = false;
- Dispatch(action, argument);
+ dispatch(action, argument);
show_sc = tmp_sc;
//return 0;
void LyXFunc::miniDispatch(string const & s)
{
if (!s.empty()) {
- Dispatch(s);
+ dispatch(s);
}
}
-string const LyXFunc::Dispatch(string const & s)
+string const LyXFunc::dispatch(string const & s)
{
// Split command string into command and argument
string cmd;
string line = frontStrip(s);
string const arg = strip(frontStrip(split(line, cmd, ' ')));
- return Dispatch(lyxaction.LookupFunc(cmd), arg);
+ return dispatch(lyxaction.LookupFunc(cmd), arg);
}
-string const LyXFunc::Dispatch(int ac,
+string const LyXFunc::dispatch(int ac,
string const & do_not_use_this_arg)
{
lyxerr[Debug::ACTION] << "LyXFunc::Dispatch: action[" << ac
meta_fake_bit = 0;
if (owner->view()->available())
// cancel any selection
- Dispatch(LFUN_MARK_OFF);
+ dispatch(LFUN_MARK_OFF);
setMessage(N_("Cancel"));
break;
// --- Menus -----------------------------------------------
case LFUN_MENUNEW:
- MenuNew(false);
+ menuNew(false);
break;
case LFUN_MENUNEWTMPLT:
- MenuNew(true);
+ menuNew(true);
break;
case LFUN_CLOSEBUFFER:
- CloseBuffer();
+ closeBuffer();
break;
case LFUN_MENUWRITE:
break;
case LFUN_FILE_OPEN:
- Open(argument);
+ open(argument);
break;
case LFUN_LATEX_LOG:
--sel; // sel 1..., but layout 0...
// Pretend we got the name instead.
- Dispatch(int(LFUN_LAYOUT),
+ dispatch(int(LFUN_LAYOUT),
textclasslist.NameOfLayout(owner->view()
->buffer()->params.textclass,
sel));
} else {
p.setContents( argument );
}
- Dispatch(LFUN_CITATION_INSERT, p.getAsString());
+ dispatch(LFUN_CITATION_INSERT, p.getAsString());
} else
owner->getDialogs()->createCitation( p.getAsString() );
}
while (argument.find(';') != string::npos) {
string first;
argument = split(argument, first, ';');
- Dispatch(first);
+ dispatch(first);
}
}
break;
}
-void LyXFunc::MenuNew(bool fromTemplate)
+void LyXFunc::menuNew(bool fromTemplate)
{
string initpath = lyxrc.document_path;
}
-void LyXFunc::Open(string const & fname)
+void LyXFunc::open(string const & fname)
{
string initpath = lyxrc.document_path;
}
-void LyXFunc::CloseBuffer()
+void LyXFunc::closeBuffer()
{
if (bufferlist.close(owner->buffer()) && !quitting) {
if (bufferlist.empty()) {
LyXFunc(LyXView *);
/// LyX dispatcher, executes lyx actions.
- string const Dispatch(int action, string const & arg = string());
+ string const dispatch(int action, string const & arg = string());
/// The same but uses the name of a lyx command.
- string const Dispatch(string const & cmd);
+ string const dispatch(string const & cmd);
///
void miniDispatch(string const & cmd);
// I think the following should be moved to BufferView. (Asger)
///
- void MenuNew(bool fromTemplate);
+ void menuNew(bool fromTemplate);
///
- void Open(string const &);
+ void open(string const &);
///
void doImport(string const &);
///
- void CloseBuffer();
+ void closeBuffer();
///
void reloadBuffer();
///
string rval, buf;
if (action>= 0) {
- rval = serv->func->Dispatch(action, arg);
+ rval = serv->func->dispatch(action, arg);
} else {
rval = "Unknown command";
}
MakeDisplayPath(vcs->owner()->fileName(), 50),
_("Save document and proceed?"))) {
vcs->owner()->getUser()->owner()
- ->getLyXFunc()->Dispatch(LFUN_MENUWRITE);
+ ->getLyXFunc()->dispatch(LFUN_MENUWRITE);
}
// Maybe the save fails, or we answered "no". In both cases,
MakeDisplayPath(vcs->owner()->fileName(), 50),
_("Save document and proceed?"))) {
vcs->owner()->getUser()->owner()
- ->getLyXFunc()->Dispatch(LFUN_MENUWRITE);
+ ->getLyXFunc()->dispatch(LFUN_MENUWRITE);
}
// Maybe the save fails, or we answered "no". In both cases,
// KmodInfo
KmodInfo::KmodInfo()
{
+#if 0
exception_list = 0;
+#endif
}
+#if 0
// Default Trans
bool DefaultTrans::init_ = false;
return k.normalkey(c);
}
#endif
-
+#endif
// Trans class
Trans::Trans()
{
+#if 0
for (int i = 0; i < TEX_MAX_ACCENT + 1; ++i)
kmod_list_[i] = 0;
+#endif
}
}
-void Trans::InsertException(Trans::keyexc & exclist, char c,
+void Trans::InsertException(KmodException & exclist, char c,
string const & data, bool flag, tex_accent accent)
{
+#if 0
keyexc p = new Keyexc;
p->next = exclist;
p->c = c;
p->accent = accent;
exclist = p;
+#else
+ Keyexc p;
+ p.c = c;
+ p.data = data;
+ p.combined = flag;
+ p.accent = accent;
+ exclist.insert(exclist.begin(), p);
+ // or just
+ // exclist.push_back(p);
+#endif
}
-void Trans::FreeException(Trans::keyexc & exclist)
+void Trans::FreeException(KmodException & exclist)
{
+#if 0
Trans::keyexc p = exclist;
while (p) {
p = exclist->next;
delete exclist;
exclist = p;
}
+#else
+ exclist.clear();
+#endif
}
void Trans::FreeKeymap()
{
+#if 0
for (int i = 0; i < 256; ++i)
if (!keymap_[i].empty()) {
keymap_[i].erase();
delete kmod_list_[i];
kmod_list_[i] = 0;
}
+#else
+ kmod_list_.clear();
+ keymap_.clear();
+#endif
}
void Trans::AddDeadkey(tex_accent accent, string const & keys)
#endif
{
+#if 0
if (kmod_list_[accent]) {
FreeException(kmod_list_[accent]->exception_list);
delete kmod_list_[accent];
}
- kmod_list_[accent] = new kmod_list_decl;
+ kmod_list_[accent] = new KmodInfo;
kmod_list_[accent]->data = keys;
kmod_list_[accent]->accent = accent;
+#else
+ KmodInfo tmp;
+ tmp.data = keys;
+ tmp.accent = accent;
+ kmod_list_[accent] = tmp;
+#endif
#if 0
if (allowed == "native") {
kmod_list_[accent]->allowed= lyx_accent_table[accent].native;
} else {
-#endif
-#if 0
kmod_list_[accent]->allowed = allowed;
-#endif
-#if 0
}
-#endif
-
+
for (string::size_type i = 0; i < keys.length(); ++i) {
string & temp =
keymap_[static_cast<unsigned char>(keys[i])];
temp += char(0);
temp += char(accent);
}
+#else
+ for (string::size_type i = 0; i < keys.length(); ++i) {
+ string tmp;
+ tmp += char(0);
+ tmp += char(accent);
+ keymap_[keys[i]] = tmp;
+ }
+#endif
+#if 0
kmod_list_[accent]->exception_list = 0;
+#endif
}
tex_accent accent_2= getkeymod(str);
if (accent_2 == TEX_NOACCENT) return -1;
+#if 0
if (kmod_list_[accent_1] == 0
|| kmod_list_[accent_2] == 0)
return -1;
+#else
+ std::map<int, KmodInfo>::iterator it1 =
+ kmod_list_.find(accent_1);
+ std::map<int, KmodInfo>::iterator it2 =
+ kmod_list_.find(accent_2);
+ if (it1 == kmod_list_.end()
+ || it2 == kmod_list_.end()) {
+ return -1;
+ }
+#endif
// Find what key accent_2 is on - should
// check about accent_1 also
+#if 0
int key = 0;
for (; key < 256; ++key) {
if (!keymap_[key].empty()
} else
return -1;
- InsertException(kmod_list_[accent_1]->exception_list,
+ InsertException(kmod_list_[accent_1].exception_list,
static_cast<char>(key), allowed,
true, accent_2);
+#else
+ std::map<int, string>::iterator it = keymap_.begin();
+ std::map<int, string>::iterator end = keymap_.end();
+ for (; it != end; ++it) {
+ if (!it->second.empty()
+ && it->second[0] == 0
+ && it->second[1] == accent_2)
+ break;
+ }
+ string allowed;
+ if (lex.next()) {
+ allowed = lex.GetString();
+ lyxerr[Debug::KBMAP] << "allowed: "
+ << allowed << endl;
+ } else {
+ return -1;
+ }
+
+ InsertException(kmod_list_[accent_1].exception_list,
+ static_cast<char>(it->first), allowed,
+ true, accent_2);
+#endif
}
break;
case KMAP: {
if (lex.next(true)) {
string string_to = lex.text();
- //char * string_to =
- // strcpy(new char[strlen(t)+1], t);
+#if 0
+ keymap_[key_from] = string_to;
+#else
keymap_[key_from] = string_to;
+#endif
if (lyxerr.debugging(Debug::KBMAP))
lyxerr << "\t`" << string_to << "'"
<< endl;
} else
return -1;
- InsertException(kmod_list_[accent]->exception_list,
+ InsertException(kmod_list_[accent].exception_list,
key, str);
break;
}
bool Trans::isAccentDefined(tex_accent accent, KmodInfo & i) const
{
+#if 0
if (kmod_list_[accent] != 0) {
i = *kmod_list_[accent];
return true;
}
return false;
+#else
+ std::map<int, KmodInfo>::const_iterator cit = kmod_list_.find(accent);
+ if (cit != kmod_list_.end()) {
+ i = cit->second;
+ return true;
+ }
+ return false;
+#endif
}
if (t.empty() && c != 0) {
return k.normalkey(c);
} else if (!t.empty() && t[0] != char(0)) {
- return k.normalkey(c);
+ //return k.normalkey(c);
+ return t;
} else {
+#if 0
return k.deadkey(c,
*kmod_list_[static_cast<tex_accent>(t[1])]);
+#else
+ return k.deadkey(c,
+ kmod_list_[static_cast<tex_accent>(t[1])]);
+#endif
}
}
#endif
#pragma interface
#endif
+#include <map>
+
#include "tex-accent.h"
#include "LString.h"
#include "trans_decl.h"
class TransManager;
+#if 0
/**
TransInterface: the interface that every translation class
should obey too.
///
static bool init_;
};
-
+#endif
/**
Trans: holds a .kmap file
*/
-class Trans : public TransInterface {
+//class Trans : public TransInterface {
+class Trans {
public:
///
Trans();
///
- virtual ~Trans();
+ ~Trans();
///
int Load(string const & language);
bool isAccentDefined(tex_accent, KmodInfo &) const;
private:
+#if 0
///
typedef KmodInfo kmod_list_decl;
///
typedef KmodException keyexc;
+#endif
#if 0
///
void AddDeadkey(tex_accent, string const &, string const &);
///
inline string const & Match(unsigned char c);
///
- void InsertException(keyexc & exclist, char c,
+ void InsertException(KmodException & exclist, char c,
string const & data, bool = false,
tex_accent = TEX_NOACCENT);
///
- void FreeException(keyexc & exclist);
+ void FreeException(KmodException & exclist);
///
string name_;
+#if 0
///
string keymap_[256];
+#else
+ std::map<int, string> keymap_;
+#endif
+#if 0
///
kmod_list_decl * kmod_list_[TEX_MAX_ACCENT+1];
-
+#else
+ ///
+ //KmodInfo * kmod_list_[TEX_MAX_ACCENT+1];
+ std::map<int, KmodInfo> kmod_list_;
+#endif
};
///
string const & Trans::Match(unsigned char c)
{
+#if 0
return keymap_[c];
+#else
+ std::map<int, string>::iterator it = keymap_.find(c);
+ if (it != keymap_.end()) {
+ return it->second;
+ }
+ static string dummy;
+ return dummy;
+#endif
}
#endif
#ifndef Trans_Decl_h
#define Trans_Decl_h
+#include <list>
+
#include "LString.h"
#include "tex-accent.h"
char c;
/// exception data
string data;
+#if 0
///
Keyexc * next;
+#endif
/// Combination with another deadkey
bool combined;
/// The accent comined with
tex_accent accent;
};
+#if 0
///
typedef Keyexc * KmodException;
+#else
+///
+typedef std::list<Keyexc> KmodException;
+#endif
///
struct KmodInfo {
{
deadkey_ = deadkey2_ = 0;
deadkey_info_.accent = deadkey2_info_.accent = TEX_NOACCENT;
+#if 0
comb_info_ = 0;
+#endif
}
#else
string const TransDeadkeyState::normalkey(char c)
{
+#if 0
string res;
// Check if it is an exception
}
currentState = init_state_;
return res;
+#else
+ string res;
+
+ KmodException::iterator it = deadkey_info_.exception_list.begin();
+ KmodException::iterator end = deadkey_info_.exception_list.end();
+
+ for (; it != end; ++it) {
+ if (it->c == c) {
+ res = it->data;
+ break;
+ }
+ }
+ if (it == end) {
+ res = DoAccent(c, deadkey_info_.accent);
+ }
+ currentState = init_state_;
+ return res;
+#endif
}
#endif
}
// Check if it is a combination or an exception
+#if 0
KmodException l;
l = deadkey_info_.exception_list;
}
l = l->next;
}
-
+#else
+ KmodException::const_iterator cit = deadkey_info_.exception_list.begin();
+ KmodException::const_iterator end = deadkey_info_.exception_list.end();
+ for (; cit != end; ++cit) {
+ if (cit->combined == true && cit->accent == d.accent) {
+ deadkey2_ = c;
+ deadkey2_info_ = d;
+ comb_info_ = (*cit);
+ currentState = combined_state_;
+ return string();
+ }
+ if (cit->c == c) {
+ res = cit->data;
+ deadkey_ = 0;
+ deadkey_info_.accent = TEX_NOACCENT;
+ currentState = init_state_;
+ return res;
+ }
+ }
+#endif
// Not a combination or an exception.
// Output deadkey1 and keep deadkey2
// Could not find an encoding
InsetLatexAccent ins(str);
if (ins.canDisplay()) {
- text->insertInset(current_view, new InsetLatexAccent(ins));
+ text->insertInset(current_view,
+ new InsetLatexAccent(ins));
} else {
insertVerbatim(str, text);
}
return;
}
- string tmp; tmp += static_cast<char>(enc.second);
+ string tmp;
+ tmp += static_cast<char>(enc.second);
insertVerbatim(tmp, text);
}
i.allowed = lyx_accent_table[accent].native;
#endif
i.data.erase();
+#if 0
i.exception_list = 0;
-
+#endif
string res = trans_fsm_.currentState->deadkey(c, i);
insert(res, t);
} else {
char deadkey2_;
///
KmodInfo deadkey2_info_;
+#if 0
///
KmodException comb_info_;
+#else
+ ///
+ Keyexc comb_info_;
+#endif
///
TransState * init_state_;
///
cmd += OnlyFilename(owner_->fileName());
cmd += "\"";
doVCCommand(cmd, owner_->filepath);
- owner_->getUser()->owner()->getLyXFunc()->Dispatch("buffer-reload");
+ owner_->getUser()->owner()->getLyXFunc()->dispatch("buffer-reload");
}
{
doVCCommand("ci -q -u -m\"" + msg + "\" \""
+ OnlyFilename(owner_->fileName()) + "\"", owner_->filepath);
- owner_->getUser()->owner()->getLyXFunc()->Dispatch("buffer-reload");
+ owner_->getUser()->owner()->getLyXFunc()->dispatch("buffer-reload");
}
owner_->markLyxClean();
doVCCommand("co -q -l \""
+ OnlyFilename(owner_->fileName()) + "\"", owner_->filepath);
- owner_->getUser()->owner()->getLyXFunc()->Dispatch("buffer-reload");
+ owner_->getUser()->owner()->getLyXFunc()->dispatch("buffer-reload");
}
// We ignore changes and just reload!
owner_->markLyxClean();
owner_->getUser()->owner()
- ->getLyXFunc()->Dispatch("buffer-reload");
+ ->getLyXFunc()->dispatch("buffer-reload");
}
{
doVCCommand("cvs -q add -m \"" + msg + "\" \""
+ OnlyFilename(owner_->fileName()) + "\"", owner_->filepath);
- owner_->getUser()->owner()->getLyXFunc()->Dispatch("buffer-reload");
+ owner_->getUser()->owner()->getLyXFunc()->dispatch("buffer-reload");
}
doVCCommand("cvs -q commit -m \"" + msg + "\" \""
+ OnlyFilename(owner_->fileName()) + "\"",
owner_->filepath);
- owner_->getUser()->owner()->getLyXFunc()->Dispatch("buffer-reload");
+ owner_->getUser()->owner()->getLyXFunc()->dispatch("buffer-reload");
}
owner_->filepath);
owner_->markLyxClean();
owner_->getUser()->owner()
- ->getLyXFunc()->Dispatch("buffer-reload");
+ ->getLyXFunc()->dispatch("buffer-reload");
}