if a float writes to the same auxfile as an existing float. E.g., in the
aguplus classes, we have a plate float that writes to lof and so is just
treated as a figure, for TOC purposes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37427 a592a061-630c-0410-9148-cb99ea01b6c8
ListCommand without our writing it to the menu twice. There's a minor
annoyance, which is that we always take the list name from the first
declaration of the Float, but it's not clear whether this is a real
issue.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37424 a592a061-630c-0410-9148-cb99ea01b6c8
and added selection of entire find/replace WAs when switching
among them on Tab/Alt+Tab.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37413 a592a061-630c-0410-9148-cb99ea01b6c8
- go back to Maping=tex-text for XeTeX and use Ligatures=TeX only for LuaTeX.
This gets users of older distributions (such as TeXLive 2009) back into the XeTeX game.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37402 a592a061-630c-0410-9148-cb99ea01b6c8
all types requiring the exact same code, as suggested by Tommaso.
This allows to simply add a single-line instantiation declaration
if there's the need of adding another type requiring the same code.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37366 a592a061-630c-0410-9148-cb99ea01b6c8
blank lines may be inadvertently output. This is achieved by using two
special iomanip-like variables (breakln and safebreakln) in the lyx::
namespace. When they are inserted in the stream, a newline is output
only if not already at the beginning of a line. The difference between
breakln and safebreakln is that, if needed, the former outputs '\n'
and the latter "%\n".
In future, the new class will also be used for counting the number of
newlines issued. Even if the infractrure for doing that is already in
place, the counting is essentially still done the old way.
There are still places in the code where the functionality of the
class could be used, most probably. ATM, it is used for InsetTabular,
InsetListings, InsetFloat, and InsetText.
The Comment and GreyedOut insets required a special treatment and a
new InsetLayout parameter (Display) has been introduced. The default
for Display is "true", meaning that the corresponding latex
environment is of "display" type, i.e., it stands on its own, whereas
"false" means that the contents appear inline with the text. The
latter is the case for both Comment and GreyedOut insets.
Mostly, the only visible effects on latex exports should be the
disappearing of some redundant % chars and the appearing/disappearing
of null {} latex groups after a comment or lyxgreyedout environments
(they are related to the presence or absence of a space immediately
after those environments), as well as the fact that math environments
are now started on their own lines.
As a last thing, only the latex code between \begin{document} and
\end{document} goes through the new class, the preamble being directly
output through odocstream, as usual.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37360 a592a061-630c-0410-9148-cb99ea01b6c8
If an optional argument can be followed by another one, we need to use
getFullOpt(). Otherwise it would not be possible to parse \foo[][bar].
Remove getOptContent to avoid confusion (it does exactly the same as
getArg('[', ']') which is used in most places.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37354 a592a061-630c-0410-9148-cb99ea01b6c8
At the end escape for fsync would be the least hackish solution
but it needs somebody with ext4 to test with.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37348 a592a061-630c-0410-9148-cb99ea01b6c8
This paves the way for having a shortcut for buffer-view and buffer-update
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37338 a592a061-630c-0410-9148-cb99ea01b6c8
* in converters, make sure that $$p and $$r are slash-terminated paths (like in viwers, BTW)
* pass the full intput path to lyxsweave.R
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37337 a592a061-630c-0410-9148-cb99ea01b6c8
(when replacing text which is longer than the replaced contents in math mode and similar).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37335 a592a061-630c-0410-9148-cb99ea01b6c8
with this sequence:
-) C-N (new doc)
-) C-S-f (open advanced find dialog)
-) Alt-Tab (switch to other application)
-) Alt-Tab (switch back to LyX)
the focus now is on the main document WA. I think it should be back on the Find WA where I was before the Alt-Tab.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37334 a592a061-630c-0410-9148-cb99ea01b6c8
The quick solution is to output a % sign before \n. The better one
would be doing as in mathed, but it is not so straightforward.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37320 a592a061-630c-0410-9148-cb99ea01b6c8
Actually, this was an oversight in r33226. There is no need to touch the physical cursor in this method.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37310 a592a061-630c-0410-9148-cb99ea01b6c8
Try to recognize modules.
Again, this is needed because the complete LyX preamble is ignored.
It is not possible to recognize a module in all cases, but at least the simple
ones are handled now. As a prerequisite I also had to revive the filling of
known_environments. This has been removed (probably by accident) some time ago.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37306 a592a061-630c-0410-9148-cb99ea01b6c8
- translate the arguments of \texorpdfstring, so that the floating footnote
code gets enabled
- honor the ForcePlainLayout flag of insets like the Index inset
- remove hardcoded \url support, this is handled by the general Flex inset code
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37297 a592a061-630c-0410-9148-cb99ea01b6c8
and the converters is also used by the main thread (getStatus).
LyX.exe!lyx::Buffer::doExport
LyX.exe!lyx::Buffer::preview(
LyX.exe!std::tr1::_Pmf_caller3<
LyX.exe!std::tr1::_Pmf_caller3<
LyX.exe!std::tr1::_Callable_pmf<
LyX.exe!std::tr1::_Bind3<
LyX.exe!std::tr1::_Bind_base<
LyX.exe!lyx::frontend::GuiView::GuiViewPrivate::runAndDestroy<
LyX.exe!lyx::frontend::GuiView::GuiViewPrivate::previewAndDestroy(
LyX.exe!QtConcurrent::StoredFunctorCall3<
LyX.exe!QtConcurrent::RunFunctionTask(
QtCored4.dll!QThreadPoolThread::run(
QtCored4.dll!QThreadPrivate::start(
msvcr100d.dll!_callthreadstartex()
msvcr100d.dll!_threadstartex(void * ptd)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37292 a592a061-630c-0410-9148-cb99ea01b6c8
parser discards all needed packages like calc.sty or framed.sty, so the
resulting document would be uncompilable with those boxes as ERT.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37287 a592a061-630c-0410-9148-cb99ea01b6c8
Make Graph more thread save by removing unneeded sharing of data between function calls:
1. Q_
When Q_ is used then it always has been cleared before usage in bfs_init
(if bfs_init returns false Q_ is not used).
Therefore we could make Q_ local to the functions.
2. vertices_[].path
.path is only used in getPath, and the pathes are always cleared before usage,
so the pathes could also be local.
The locks are not needed here any more. When there will be errors due to
race conditions, we could not solve them here. We have to lock at higher
places.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37257 a592a061-630c-0410-9148-cb99ea01b6c8
rc2rc project. (Was there a bug number for that? I can't find it, if
there was.)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37247 a592a061-630c-0410-9148-cb99ea01b6c8
preparatory to prefs2prefs conversion here, which will be the last piece
of that work.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37235 a592a061-630c-0410-9148-cb99ea01b6c8
something else has been provided. (This is only an issue when no spell
checkers are detected.)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37234 a592a061-630c-0410-9148-cb99ea01b6c8
All the LFUNs listed in the release notes should be properly converted.
If not, then changes should be made to the file:
lib/scripts/prefs2prefs-lfuns.py
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37231 a592a061-630c-0410-9148-cb99ea01b6c8
1. open LYX
2. CRTL-N
3. CRTL-D hold D --> crash
Graph must be thread save to fix this.
And for sure, we need a mutex also later.
Mutex is a simple wrapper around QMutex, with
pseudo-value semantic.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37222 a592a061-630c-0410-9148-cb99ea01b6c8
accumulate for each round trip, since LyX writes \protect if needed)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37214 a592a061-630c-0410-9148-cb99ea01b6c8
longtable or not, e.g., in the docbook and xhtml output routines.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37204 a592a061-630c-0410-9148-cb99ea01b6c8
The reason we don't need to do what I say we don't need to do is that a
given counter doesn't really care about whether it has a master. It's
when the master is stepped that we check for which other ones to reset.
So if the master doesn't exist, nothing will happen, anyway.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37197 a592a061-630c-0410-9148-cb99ea01b6c8
noticed that article, for example, still has a counter "chapter". This
surprised me.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37193 a592a061-630c-0410-9148-cb99ea01b6c8
of things like:
pit.push_back(CursorSlice(*this));
which I've had to change to:
pit.push_back(CursorSlice(const_cast<InsetCaption &>(*this)));
and similarly in a few other places.
If anyone thinks we should instead have:
explicit CursorSlice(Inset const &);
then we can also do that.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37192 a592a061-630c-0410-9148-cb99ea01b6c8
LyX would output the parsed stuff unconditionally, so we must not translate
it in LyX document settings.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37191 a592a061-630c-0410-9148-cb99ea01b6c8
better than what we had, anyway, since we do not calculate the tocstring
unless we need it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37190 a592a061-630c-0410-9148-cb99ea01b6c8
- Add missing babel synonyms (taken from a standard TeXLive 2010 install).
Some synonyms might still be missing (if they are defined not by babel
itself, but additional packages). Adding these is now simple: Only
known_languages and known_coded_languages need to be touched.
- Translate babel language name arguments of \foreignlanguage and
\selectlanguage to LyX names.
- Translate second argument of \foreignlanguage to LyX.
- Cleanup mixed language names in the preamble parser: Now all checks are
done with LyX names, not a mix of babel and LyX names. This sets correct
quotes even if the language as given as an alias.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37188 a592a061-630c-0410-9148-cb99ea01b6c8
then output \setcounter macros during snippet generation, so that we get
the right equation values.
Note: It would be possible to use this same machinery to fix bugs in
instant preview, e.g., that you always get things like (0.3) as equation
numbers, if you use equations numbered by section. I'll perhaps post a
patch for that.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37186 a592a061-630c-0410-9148-cb99ea01b6c8
still be a mess in many cases, but hopefully we won't have to go here
very often.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37181 a592a061-630c-0410-9148-cb99ea01b6c8
numbering in XHTML output, but it's just as easy to fix this in the LyX
display.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37177 a592a061-630c-0410-9148-cb99ea01b6c8
the timeout. 30 minutes should be enough, also for very big documents.
#7228
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37176 a592a061-630c-0410-9148-cb99ea01b6c8
not break in PDF table of contents (using texorpdfstring).
Uwe, this should allow you to remove some ERT from the documentation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37164 a592a061-630c-0410-9148-cb99ea01b6c8
lib/doc/Math.lyx, since tex2lyx swallows the LyX part of the preamble, and
thus \shortcut would not be defined.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37149 a592a061-630c-0410-9148-cb99ea01b6c8
Fix missing \size reset after sectioning environments.
Fix invalid \lang default (use english instead, as in the preamble)
Convert hard coded layout output of caption insets to Context class.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37147 a592a061-630c-0410-9148-cb99ea01b6c8
Unfortunately the commandline export of InsetInfo is still broken for MENU_INFO.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37134 a592a061-630c-0410-9148-cb99ea01b6c8
misinterpreting "\}" as "}" when it occured inside a pair of unescaped
braces, like in "\code{@\{*\}r||p\{1in\}@\{*\}}".
The reason for this bug is that Token::character() behaves differently in
tex2lyx than in mathed. See the comment in Parser.h for a more general fix.
For now I played on the safe side and only changed those places where I
definitely know that the old code was wrong.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37117 a592a061-630c-0410-9148-cb99ea01b6c8
- use correct params for INDEX_CODE and INDEX_PRINT_CODE (bug 7180).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37104 a592a061-630c-0410-9148-cb99ea01b6c8
Now, when hovering the tabs, the full paths are shown as a tooltip.
see r37084.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37101 a592a061-630c-0410-9148-cb99ea01b6c8
The whole thing was introduced in r28154.
JMarc, could you improve the description doxies for selection-paste and primary-selection-paste ?
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37097 a592a061-630c-0410-9148-cb99ea01b6c8
When a document with a InsetTOC was closed, the outline was closed. But this shouldn't happen because editedInset("toc") does never return something.
The reason that this happened was that if currentBufferView() is 0, we don't even care wehther inset was specified. If inset is specified, it should match the editedInset.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37094 a592a061-630c-0410-9148-cb99ea01b6c8
Now, when hovering the tabs, the longer name is shown as a tooltip.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37084 a592a061-630c-0410-9148-cb99ea01b6c8
Now, when hovering the lastfiles menu, the full file names are shown in the statusbar.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37083 a592a061-630c-0410-9148-cb99ea01b6c8
When applying the preference we need to save the full session information, because when this information is not yet saved, we will lose it forever. We can enter the preferences without a saved state when we start LyX with a modified default.ui.
see also: r37075 and r37076.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37077 a592a061-630c-0410-9148-cb99ea01b6c8
However, it cannot hurt to warn the user and fall back to the defaults in case.
The real cause of bug #7099 is something else (which I will fix soon).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37076 a592a061-630c-0410-9148-cb99ea01b6c8
In GuiApplication::readUIFile() the settings for views gets removed if the ui file is newer than the saved timestamp in the settings. Later the non existing settings will be used to initialize the visibility. The default value for a non existing setting is 0. The visibility_ variable does never get changed afterwards. And therefore
we will again write 0 to the registry.
We should have read the ui file instead when we can't find the registry value.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37075 a592a061-630c-0410-9148-cb99ea01b6c8
The problem is/was that when copying an InsetTableCell?, the macrocontext_position_ and the buffer_ were not copied. That's why in InsetTabular?@splitCell@521 and in InsetTabular::TeXRow() and in InsetTabular::metrics we manually copy this into the new object.
However, splitCell() returns the object by-value. So, when we call
InsetTableCell tail = splitCell(head, column_info[c].decimal_point, hassep);
the new object is copied into tail and we lose the buffer_ and macro_contextposition. Later we will crash.
What does *nix in this case ? Apparently they don't make buffer and/or macro_contextposition 0.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37072 a592a061-630c-0410-9148-cb99ea01b6c8
Now, there is the bug that autoallow is incorrectly set to true when visibility_ has the Visibility::SAMEROW flag. One shouldn't use >= on an enum (GuiToolbar::setVisibility), as newly added items will exhibit unexpected behaviour.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37068 a592a061-630c-0410-9148-cb99ea01b6c8
Improve heuristic for outputting \bibliographystyle: Now it is suppressed
if \bibliography follows immediately, since LyX adds it automatically in that
case.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37066 a592a061-630c-0410-9148-cb99ea01b6c8
- Replace special verbatim commands by standard LaTeX, since it would be
extremely difficult to make tex2lyx understand them)
- Comment duplicated \bibliography{xampl}, since LaTeX cannot handle two
\bibliography calls
- Fix a regression with spaces after commands, introduced in r36943
- Parse \multicolumn with space/comments between two arguments correctly
- Parse optional arguments correctly if there are space or comments between
the command and the argument
- Remove duplicate "LyX" phrase handling (I overlooked that in r37052)
- Add new commands created with \let to the list of known commands. This is
needed to parse the arguments correctly
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37064 a592a061-630c-0410-9148-cb99ea01b6c8
We have to call cap::replaceSelection before determining whether we can insert an InsetQuote or a normal quote.
At least we should have updated the par variable after calling cap::replaceSelection, because the paragraph might have been deleted.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37063 a592a061-630c-0410-9148-cb99ea01b6c8
This hopefully fixes#6171, i.e., when copying from main document with non-English language to find/replace WAs,
the pasted text is not underlined anymore.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37057 a592a061-630c-0410-9148-cb99ea01b6c8
The automatic replacement in LyX is pretty broken (see bug 4752).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37055 a592a061-630c-0410-9148-cb99ea01b6c8
Please don't add new features to tex2lyx without testing.
In this case, the test case was even provided in test-insets.tex.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37051 a592a061-630c-0410-9148-cb99ea01b6c8
The reasons for doing this in tex2lyx instead of an external script are:
- Correct choice of latex/pdflatex export
- Using the correct LyX executable regardless of running inplace or from an
installation, or with or without version suffix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37049 a592a061-630c-0410-9148-cb99ea01b6c8
- update screen font sizes in dialog after prefs change, since the localization of float values might have changed.
(fixes bug 6771).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37035 a592a061-630c-0410-9148-cb99ea01b6c8
When creating the QFontMetrics object, we should specify a QPaintDevice. 0 is a paint device which is screen-compatible or pixmap-compatible. This makes sure that the correct DPI is used in font metrics calculations.
see also:
http://bugreports.qt.nokia.com/browse/QTBUG-16331.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37030 a592a061-630c-0410-9148-cb99ea01b6c8
344: Remove pdf_pagebackref header flag
345: Nothing to do (this is a docbook-only change)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37015 a592a061-630c-0410-9148-cb99ea01b6c8
335: Create space inset in new syntax
336: Nothing to do (empty lyx2lyx conversion)
337: Nothing to do (tex2lyx does use the display flag)
338-339: Nothing to do (empty lyx2lyx conversion)
340: Nothing to do (tex2lyx does not output empty layout names)
341-342: Nothing to do (empty lyx2lyx conversion)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37013 a592a061-630c-0410-9148-cb99ea01b6c8
331: Set the caption flag for longtable caption rows
332: Nothing to do (empty lyx2lyx conversion)
333: Nothing to do (tex2lyx did already use the new style names because it
uses the current layout files)
334: Nothing to do (tex2lyx did already produce the new format, since it
used the LaTeX paper names also in the output and did not suffer from
bug 4868)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37012 a592a061-630c-0410-9148-cb99ea01b6c8
324: Create newline inset in new syntax
325: Nothing to do (tex2lyx does not support the japanese language)
326-327: Nothing to do (empty lyx2lyx conversion)
328: Nothing to do (tex2lyx did never support embedding of files)
329-330: Nothing to do (empty lyx2lyx conversion)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37011 a592a061-630c-0410-9148-cb99ea01b6c8
321: Move leftlines/rightlines from column headers to cells
322: Nothing to do (tex2lyx does not produce plain layouts)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37009 a592a061-630c-0410-9148-cb99ea01b6c8
line, if we were too big. Now, we put "..." at the end of the last line.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36988 a592a061-630c-0410-9148-cb99ea01b6c8
to be treated as part of the document. For example, the footnote numbers
in LyX are wrong prior to this patch.
This will also affect word and character count, but should not affect
anything else. If that seems wrong, we can either (a) explicitly exclude
notes from the word count or else (b) introduce
bool countWordsInInset() const;
and call that, instead.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36976 a592a061-630c-0410-9148-cb99ea01b6c8
that also makes sure it doesn't do more work than it needs to do, by
limiting the size to 40 characters. Previously, InsetBranch::addToToc()
would have added a string representing the entire contents of the
branch! It's hard to imagine that having to recalculate that sort of
thing doesn't cause some problems with speed, especially in documents
with lots of notes and branches and such.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36974 a592a061-630c-0410-9148-cb99ea01b6c8