size_t const n = cmd.size() - 1;
if (cmd != "cite" && cmd[n] == '*') {
s.full = true;
- cmd = cmd.substr(0,n);
+ cmd = cmd.substr(0, n);
}
char const * const * const last = citeCommands + nCiteCommands;
if (runparams.flavor == OutputParams::XML)
top += params().language->code();
else
- top += params().language->code().substr(0,2);
+ top += params().language->code().substr(0, 2);
top += '"';
if (!params().options.empty()) {
{
RGBColor c;
LASSERT(x11hexname.size() == 7 && x11hexname[0] == '#', /**/);
- c.r = hexstrToInt(x11hexname.substr(1,2));
- c.g = hexstrToInt(x11hexname.substr(3,2));
- c.b = hexstrToInt(x11hexname.substr(5,2));
+ c.r = hexstrToInt(x11hexname.substr(1, 2));
+ c.g = hexstrToInt(x11hexname.substr(3, 2));
+ c.b = hexstrToInt(x11hexname.substr(5, 2));
return c;
}
size_t i = n.find(':');
if (i == string::npos)
break;
- n = n.substr(0,i);
+ n = n.substr(0, i);
}
return plain_insetlayout_;
}
Coords::const_iterator it = preamble_coords_.find(current_id_);
if (it == preamble_coords_.end())
// First time we open this one.
- preamble_coords_[current_id_] = make_pair(0,0);
+ preamble_coords_[current_id_] = make_pair(0, 0);
else {
// Restore saved coords.
QTextCursor cur = preambleTE->textCursor();
if (!is_utf16(c))
// FIXME: QFontMetrics::leftBearingdoes not support the
// full unicode range. Once it does, we could use:
- //return metrics_.leftBearing(toqstr(docstring(1,c)));
+ //return metrics_.leftBearing(toqstr(docstring(1, c)));
return 0;
return metrics_.leftBearing(ucs4_to_qchar(c));
} else {
// FIXME: QFontMetrics::leftBearing does not support the
// full unicode range. Once it does, we could use:
- // metrics_.rightBearing(toqstr(docstring(1,c)));
+ // metrics_.rightBearing(toqstr(docstring(1, c)));
value = width(c);
}
else
return metrics_.width(qc);
} else {
- QString const s = toqstr(docstring(1,c));
+ QString const s = toqstr(docstring(1, c));
QString const us = s.toUpper();
if (s != us)
return smallcaps_metrics_.width(us);
if (is_utf16(c))
r = metrics_.boundingRect(ucs4_to_qchar(c));
else
- r = metrics_.boundingRect(toqstr(docstring(1,c)));
+ r = metrics_.boundingRect(toqstr(docstring(1, c)));
AscendDescend ad = { -r.top(), r.bottom() + 1};
// We could as well compute the width but this is not really
if (nrows > 1)
selectedLV->setCurrentIndex(idx);
else if (nrows == 1)
- selectedLV->setCurrentIndex(selectedLV->model()->index(0,0));
+ selectedLV->setCurrentIndex(selectedLV->model()->index(0, 0));
selectedHasFocus_ = (nrows > 0);
updateHook();
}
QVariant GuiWorkArea::inputMethodQuery(Qt::InputMethodQuery query) const
{
- QRect cur_r(0,0,0,0);
+ QRect cur_r(0, 0, 0, 0);
switch (query) {
// this is the CJK-specific composition window position.
case Qt::ImMicroFocus:
// but my qt 4.1.2 doesn't have expandAll()..
//tocTV->expandAll();
QModelIndexList indices = tocTV->model()->match(
- tocTV->model()->index(0,0),
+ tocTV->model()->index(0, 0),
Qt::DisplayRole, "*", -1,
Qt::MatchFlags(Qt::MatchWildcard|Qt::MatchRecursive));
string mid = out.substr(i + 13, j - i - 13);
if (mid.find("\\over") != npos)
mid = '{' + mid + '}';
- out = out.substr(0,i)
+ out = out.substr(0, i)
+ mid
+ out.substr(k + 1);
//lyxerr << "output: " << out << endl;
size_t k = get_matching_brace(out, i + 5);
if (k == npos || k + 1 == out.size())
break;
- out = out.substr(0,j - 1)
+ out = out.substr(0, j - 1)
+ "\\frac"
- + out.substr(j,i - j)
- + out.substr(i + 5,k - i - 4)
+ + out.substr(j, i - j)
+ + out.substr(i + 5, k - i - 4)
+ out.substr(k + 2);
//lyxerr << "output: " << out << endl;
i = out.find("\\over", i + 4);