#include "lyxlex.h"
#include "lyxtext.h"
#include "undo_funcs.h"
+#include "changes.h"
#include "frontends/Alert.h"
#include "frontends/Dialogs.h"
}
+Change const BufferView::getCurrentChange()
+{
+ return pimpl_->getCurrentChange();
+}
+
+
void BufferView::beforeChange(LyXText * text)
{
pimpl_->beforeChange(text);
ifstream ifs(fname.c_str());
if (!ifs) {
- Alert::alert(_("Error!"),
- _("Cannot open specified file: "),
+ Alert::err_alert(_("Error! Cannot open specified file:"),
MakeDisplayPath(fname, 50));
return false;
}
toggleSelection(false);
tt->replaceSelectionWithString(this, replacestring);
- tt->setSelectionOverString(this, replacestring);
+ tt->setSelectionRange(this, replacestring.length());
// Go back so that replacement string is also spellchecked
for (string::size_type i = 0; i < replacestring.length() + 1; ++i) {