mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 19:07:45 +00:00
Accidentally removed this code at last commit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@40908 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
38e92582af
commit
354d9700f6
@ -143,6 +143,7 @@ void ViewSourceWidget::setViewFormat()
|
|||||||
updateView();
|
updateView();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void ViewSourceWidget::updateView()
|
void ViewSourceWidget::updateView()
|
||||||
{
|
{
|
||||||
if (!bv_) {
|
if (!bv_) {
|
||||||
@ -197,6 +198,7 @@ void ViewSourceWidget::updateDefaultFormat()
|
|||||||
outputFormatCO->addItem(qt_("Default"),
|
outputFormatCO->addItem(qt_("Default"),
|
||||||
QVariant(QString("default")));
|
QVariant(QString("default")));
|
||||||
|
|
||||||
|
int index = 0;
|
||||||
vector<string> tmp = bv_->buffer().params().backends();
|
vector<string> tmp = bv_->buffer().params().backends();
|
||||||
vector<string>::const_iterator it = tmp.begin();
|
vector<string>::const_iterator it = tmp.begin();
|
||||||
vector<string>::const_iterator en = tmp.end();
|
vector<string>::const_iterator en = tmp.end();
|
||||||
@ -209,10 +211,13 @@ void ViewSourceWidget::updateDefaultFormat()
|
|||||||
// we can't presently display the LyX format itself
|
// we can't presently display the LyX format itself
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
QString const pretty =
|
QString const pretty = qt_(fmt->prettyname());
|
||||||
fmt ? qt_(fmt->prettyname()) : toqstr(format);
|
QString const qformat = toqstr(format);
|
||||||
outputFormatCO->addItem(pretty, QVariant(toqstr(format)));
|
outputFormatCO->addItem(pretty, QVariant(qformat));
|
||||||
|
if (qformat == view_format_)
|
||||||
|
index = outputFormatCO->count() -1;
|
||||||
}
|
}
|
||||||
|
outputFormatCO->setCurrentIndex(index);
|
||||||
|
|
||||||
outputFormatCO->blockSignals(false);
|
outputFormatCO->blockSignals(false);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user