Commit Graph

1898 Commits

Author SHA1 Message Date
Georg Baum
1ca55d1c8f Fix bug 3034
* src/mathed/InsetMathGrid.C: Don't declare mathed_parse_normal,
	include MathParser.h instead
	(InsetMathGrid::doDispatch): remove to_utf8, mathed_parse_normal
	takes now a docstring

	* src/mathed/MathMacroTemplate.C
	(MathMacroTemplate::read): restore the version of 1.4.x, since
	the new one did only work for macros without whitespace

	* src/mathed/MathParser.[Ch]
	(Parser): Add constructor from a docstring
	(mathed_parse_cell): Create the parser directly from the string,
	since the istream variant of tokenize() does only work if reading
	from the .lyx file
	(mathed_parse_normal): ditto
	(mathed_parse_normal): Delete the istream variant (unused)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16334 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-19 14:24:25 +00:00
Georg Baum
e208fa001b remove unused stuff
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16314 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-17 15:05:18 +00:00
Abdelrazak Younes
a68da74622 unneeded header
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16200 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-07 12:06:10 +00:00
Abdelrazak Younes
493ec52c3f * Dimension is a simple wrapper class again.
* other files: use FontMetrics::dimension() method instead of old Dimension interface.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16167 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-04 10:45:43 +00:00
Abdelrazak Younes
8f98ec35e4 This commit fixes the following bug:
http://bugzilla.lyx.org/show_bug.cgi?id=2900

The only drawback is that it requires about 20Mo extra-memory when loading the UserGuide. If it turns out to be too much, we can switch to a QHash based solution instead of a table.

* dimension.[Ch]:
  - Dimension(LyXFont const, char_typec): new ctor
  - set(LyXFont const & font, char_type c): new method.

* frontends/FontMetrics.h:
  - width(char_type): is now a pure virtual method.

* GuiFontMetrics:
  - CharMetrics: new structure;
  - the metrics cache now also cache ascent and descent. This is especially useful for mathed.

* MathSupport.[Ch]:
  - mathed_char_dim(): deleted. We now use Dimension::set() directly instead.

* rowpainter.C: fixe empty space.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16124 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-01 16:12:24 +00:00
Abdelrazak Younes
e24bf64c68 * dimension.h: new operator!=() and operator=()
* InsetBase and all derivates:
  - metrics(MetricsInfo & mi, Dimension & dim) now returns a bool (true if metrics changed).

* MathData and all derivates:
  - metrics(MetricsInfo & mi, Dimension & dim): ditto.

* RenderBase and all derivates:
  - metrics(MetricsInfo & mi, Dimension & dim): ditto.

* lyxtext.h/text.C:
  - LyXText::metrics(MetricsInfo & mi, Dimension & dim): ditto.
  - LyXText::redoParagraph(): take into account potential change in inset metrics.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16091 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-28 15:15:49 +00:00
Georg Baum
8e6e970d7b Next step of true unicode filenames: Use support::FileName instead of
std::string at many places (not all yet).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16069 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-26 21:30:39 +00:00
Abdelrazak Younes
dd91a7f6b6 * InsetMathNest::lfunMouseRelease(): keep the optimization only if there is no selection. This allows to shorten the time when the cursor is initially set at the beginning of the math inset.
* InsetMathNest::lfunMousePress(): Disable optimization introduced in revision 16006. This is because we need the box corners when navigating inside formulas.

* InsetMathNest::doDispatch(): ditto.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16011 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-22 14:45:33 +00:00
Abdelrazak Younes
1278f826c9 * BufferView::update(): handle the special case Flag == FitCursor.
* InsetMathNest.C: adjust update flags in order to avoid unneeded screen redrawing.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16006 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-21 16:58:45 +00:00
Jean-Marc Lasgouttes
502f07307f * MathMacroArgument.C (MathMacroArgument): do not use convert<> since
it may be too slow.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15996 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-20 14:07:30 +00:00
Bo Peng
7880841888 BUG 686: delete empty math box with delete/backspace key
* src/cursor.C: remove nested empty math box
	* src/mathed/InsetMathNest.C: remove the whole empty math box if it 
	  can not be deleted from within


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15990 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-19 18:33:13 +00:00
Enrico Forestieri
22be03e68c Avoid processing empty lines when reading the symbols file
* src/mathed/MathFactory.C
	(initSymbols): skip a line when it is empty or a comment.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15961 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-17 20:43:49 +00:00
Jean-Marc Lasgouttes
0f4aaa8ed4 * src/mathed/MathMacroArgument.C
(MathMacroArgument): fix creation of #digit string.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15914 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-14 08:15:38 +00:00
Georg Baum
2db7521b70 Add support for the esint package
* src/LaTeXFeatures.C
	(LaTeXFeatures::getPackages): handle esint and wasysym

	* src/mathed/MathMacroTable.[Ch]
	(requires_): New member: tell the feature this macro requires
	(MacroTable::insert): take new requires arg

	* src/mathed/MathMacroTemplate.C
	(MathMacroTemplate::asMacroData): adjust to change above

	* src/mathed/MathSupport.C
	(fontinfos): add esint10 font

	* src/mathed/InsetMathHull.C
	(InsetMathHull::doDispatch): AMS_ON -> package_on

	* src/mathed/MathMacroTable.h

	* src/mathed/MathFactory.C
	(initSymbols): read and store requires field for symbols

	* src/mathed/InsetMathSymbol.C
	(InsetMathSymbol::metrics): handle esint
	(InsetMathSymbol::takesLimits): ditto

	* src/buffer.C
	(LYX_FORMAT): update format
	(Buffer::validate): handle esint, AMS_ON -> package_on

	* src/bufferparams.C:
	(AMSTranslator): Rename to PackageTranslator
	(BufferParams::readToken): Read \use_esint
	(BufferParams::writeFile): Write \use_esint

	* src/frontends/qt4/QDocumentDialog.C: handle esint

	* src/frontends/qt4/ui/MathsUi.ui : add esint checkboxes

	* src/frontends/qt4/GuiFontLoader.C
	(symbol_fonts: Add esint10 font
	(symbolFamily): handle esint10 font
	(isChosenFont): Add comment

	* src/frontends/controllers/ControlMath.C
	(latex_varsz): Add new integral symbols

	* src/support/fontutils.C
	(win_fonts_truetype): Add esint10 font

	* src/bufferparams.h
	(enum AMS): rename to enum Package
	(use_esint): new parameter

	* src/lyxfont.[Ch]: Add esint font

	* lib/symbols: Add new integral symbols

	* lib/lyx2lyx/LyX.py
	(format_relation): Update format

	* lib/lyx2lyx/lyx_1_5.py: handle new format

	* lib/chkconfig.ltx: Test esint package

	* lib/images/math/oiintop.xpm
	* lib/images/math/sqintop.xpm
	* lib/images/math/sqint.xpm
	* lib/images/math/ointctrclockwiseop.xpm
	* lib/images/math/ointctrclockwise.xpm
	* lib/images/math/iiintop.xpm
	* lib/images/math/iintop.xpm
	* lib/images/math/sqiint.xpm
	* lib/images/math/iiint.xpm
	* lib/images/math/ointclockwiseop.xpm
	* lib/images/math/oiint.xpm
	* lib/images/math/dotsintop.xpm
	* lib/images/math/sqiintop.xpm
	* lib/images/math/ointclockwise.xpm
	* lib/images/math/iiiintop.xpm
	* lib/images/math/dotsint.xpm
	* lib/images/math/iiiint.xpm
	* lib/images/math/iint.xpm: new icons

	* lib/doc/LaTeXConfig.lyx.in: Add docs for esint package

	* lib/doc/UserGuide.lyx: Add short documentation of integral symbols

	* lib/Makefile.am: Add new files

	* development/scons/scons_manifest.py: ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15907 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-13 17:35:18 +00:00
Georg Baum
8c651169ef Revert revision 14819 and my faulty fix for it.
* src/mathed/InsetMathScript.C
	(InsetMathScript::write): Do not add braces to the nucleus

	* src/mathed/MathParser.C
	(Parser::parse1): Do not remove brace insets from the nucleus of
	script insets

	* src/mathed/InsetMathNest.C
	(InsetMathNest::script): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15859 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-11 15:26:31 +00:00
Jean-Marc Lasgouttes
a93279983d * src/mathed/InsetMathSymbol.C (metrics): remove broken mac workaround
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15824 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-09 14:47:56 +00:00
Georg Baum
d3218b9acb document docstring abuse for symbol font code points
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15791 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-07 20:46:38 +00:00
Georg Baum
aea574afa1 * src/mathed/InsetMathSymbol.C
(InsetMathSymbol::draw): Remove obsolete FIXME
	(InsetMathSymbol::draw): Microoptimization: Do not copy the string



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15789 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-07 19:29:01 +00:00
Abdelrazak Younes
95b150fee5 Fix MSVC warning.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15747 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-05 12:22:05 +00:00
Georg Baum
f498157e18 Fix comment according to Enricos explanation
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15743 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-05 08:53:52 +00:00
Abdelrazak Younes
8b7cc1b498 Convert to unicode.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15728 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-04 11:03:14 +00:00
Georg Baum
4689b5eea3 * src/mathed/MathParser.C
(Parser::parse1): Fix special handling of {}-bases to not destroy
	\xxx{\vec{H}}_0 where \xxx is an unknown command


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15712 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-03 15:05:14 +00:00
Enrico Forestieri
6b1631a8c5 Output a space if pendingSpace() is true and it is actually needed
* src/mathed/MathStream.C
	(isAlpha): new, test whether a lyx::char_type is an ascii letter.
	(operator<<): output a space if pendingSpace() is true and what follows
	begins with an ascii letter. Also update the number of lines written.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15645 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-31 20:16:47 +00:00
Georg Baum
f8b9d95ee4 Support all xymatrix arguments
* src/LaTeXFeatures.C
	(LaTeXFeatures::getPackages): Add package xy

	* src/mathed/InsetMathXYMatrix.[Ch]
	(spacing_): New
	(spacing_code_): New
	(validate): New, require xy package

	* src/mathed/InsetMathXYMatrix.C
	(InsetMathXYMatrix::write): write spacing_ and spacing_code_
	(InsetMathXYMatrix::infoize): output spacing_ and spacing_code_

	* src/mathed/MathFactory.C
	(createInsetMath): handle special arguments of xymatrix

	* src/mathed/MathParser.C
	(Parser::parse1): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15643 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-31 19:10:30 +00:00
Abdelrazak Younes
eb651c3d61 Move BufferView cached pointer out of LyXText:
* LyXText
  - bv(), bv_owner, : deleted.
  - These methods now need a (Buffer const &) argument: getFont(), applyOuterFont(), getLayoutFont(), getLabelFont(), setCharFont(), setLayout(), singleWidth(), leftMargin(), rightMargin(), computeRowMetrics(), isMainText(), spacing(), isRTL(), cursorX(), rowBreakPoint(), setRowWidth(), labelFill(), labelEnd().
  - These methods now need a (BufferView const &) argument and are propably candidates for future removal when 1.6 is opened for development: redoParagraph(), x2pos(), getRowNearY(), getColumnNearX(), checkInsetHit(), setHeightOfRow().
  - recUndo(): now need a LCursor argument.
 
* CoordCache::get(LyXText const *, pit_type):
  - now const.
  - use const_iterator instead of iterator.

* FontIterator:
  - add (Buffer const &) argument to ctor
  - buffer_: new const reference to applicable BufferView.

* InsetBase
  - xo(), yo(), covers() and neverIndent() are now const.

* InsetText::setViewCache(): deleted

All other changes are due to the LyXText and InsetBase API changes.



 
  

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15618 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-30 12:45:33 +00:00
Abdelrazak Younes
0a48776a9a Forgot that!
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15615 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-30 10:47:59 +00:00
Abdelrazak Younes
73ed0b5203 * Painter.h:
* Painter: new ctor that sets drawing_enabled_ to true.
  * setDrawingEnabled(), isDrawingEnabled(): new methods.

* QLPainter.C: only draw if drawing is enabled.

* nullpainter.h: deleted.

* rawpainter.C::paintPar(): only draw if we are inside the Paragraph.

* InsetTabular::draw(): use new Painter method instead of a NullPainter.

* InsetMathNest::drawSelection(): ditto.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15613 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-30 10:09:59 +00:00
Abdelrazak Younes
54bdecdb48 remove paperHeight() and paperWidth() in Painter and inherited classes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15589 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-28 09:36:22 +00:00
André Pönitz
4774536389 cursor is no more damaging the background. L-shaped cursor is broken right now. will fix later
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15503 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-23 11:19:17 +00:00
André Pönitz
dc94575f2b make macrfos readable again
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15479 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-22 14:37:32 +00:00
Michael Schmitt
a10629dfc6 * mathed/InsetFormulaMacro.C:
* mathed/InsetMathXYArrow.C:
	* mathed/InsetMathMBox.C: do not include non-existing MathMLStream.h


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15477 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-22 14:23:14 +00:00
André Pönitz
578baa8f98 fix reading UTF8 encoded symbol file
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15472 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-22 12:07:01 +00:00
André Pönitz
eaa81aa13e some compile fixes, more to be expected
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15465 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-22 11:00:04 +00:00
André Pönitz
de6418f377 use more unicode in math
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15462 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-22 10:15:23 +00:00
José Matox
354fb450c2 More unicode fixes for docbook.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15459 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-21 19:40:29 +00:00
Lars Gullik Bjønnes
d12c1f4b22 Fix some unicode conversion problems, more work needed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15442 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-21 11:15:37 +00:00
André Pönitz
6c300f72a2 move everything into namespace lyx
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15422 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-21 00:16:43 +00:00
Georg Baum
ffe7cb1b78 Use the new InsetCommandParams interface (inset part), from Ugras and me
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15413 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-20 16:12:49 +00:00
Enrico Forestieri
899fb06023 Fix some glitches with fixed size delimiters
* src/mathed/MathParser.C
	(parse1): behave correctly when a wrong delimiter is specified.

	* src/mathed/InsetMathBig.C
	(write): don't write a space before delimiter.

	* src/frontends/qt4/QDelimiterDialog.C
	(QDelimiterDialog): make translatable the string "Variable size".


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15397 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-20 10:43:53 +00:00
Lars Gullik Bjønnes
0d449056ef Output docbook as utf8. Probably quite a bit more work needed, but then help form a docbook person is needed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15387 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-19 21:00:33 +00:00
Georg Baum
9e86082c9a make it compile again (hopefully)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15383 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-19 19:16:33 +00:00
Georg Baum
62aedce851 Avoid an implicit character set conversion in cur.insert() in InsertChar
by changing the argument type to lyx::char_type.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15382 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-19 18:56:16 +00:00
Georg Baum
8b67659646 Use UTF8 for LaTeX export.
Known problems:
- No space is output after a \hfill. I probably broke this with the
  InsetCommand patch. I'll have a look later.
- Although the encoding is now UTF8 the arguments of the inputenc package
  are still the old ones, so LaTeX will not run.
- Labels and references with non-ASCII characters are broken. This needs to
  be fixed in lyx::support::escape(), but this is a file format change.
- Something seems to be wrong with index entries, but this is probably also
  due to the InsetCommand changes.

Have fun!


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15378 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-19 16:51:30 +00:00
Asger Ottar Alstrup
daae275cd1 - Fix math editing
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15377 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-19 16:38:13 +00:00
Georg Baum
b02242bfaf Rework InsetCommandParams interface and file storage
* src/insets/insetcommandparams.[Ch]:
	(operator[]): New, access a parameter
	(clear): New, clear all parameters
	(info_): New, stire info about this command
	(cmdname): Rename to name_
	(contents, options, sec_options): Replace with params_. Parameters
	are now stored as docstring.
	(findInfo): New factor for command info for all commands
	(read, write): Use new syntax
	(parameter set and get methods): reimplemenmt for new parameter storage

	* src/insets/insetcommand.h
	(getParam): New, get a parameter
	(setParam): New, set a parameter
	(parameter set and get methods): Adjust to InsetCommandParams changes

	* src/insets/insetbibitem.[Ch]
	(write): Remove, not needed anymore
	(directWrite): ditto

	* src/insets/insetbibitem.C
	(InsetBibitem::read): Use InsetCommand::read

	* src/insets/insetref.C
	(InsetRef::latex): Use new InsetCommandParams interface

	* src/mathed/InsetMathHull.C
	(InsetMathHull::doDispatch): ditto

	* src/text3.C
	(LyXText::dispatch): ditto

	* src/factory.C
	(createInset): Create InsetCommandParams with command name
	(readInset): ditto
	(readInset): Remove error message for bibitem, since bibitem is
	now a normal command inset

	* src/buffer.C: Bump file format number

	* src/frontends/controllers/ControlCommand.[Ch]
	(ControlCommand): take an additional command name parameter

	* src/text.C
	(readParToken): Remove code for \bibitem

	* lib/lyx2lyx/LyX.py: Bump latest file format number

	* lib/lyx2lyx/lyx_1_5.py
	(convert_bibitem, convert_commandparams): new, convert to new format
	(revert_commandparams): new, convert to old format

	* development/FORMAT: document new format

	* many other files: Adjust to the changes above


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15357 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-17 21:07:16 +00:00
Abdelrazak Younes
4cc7a7708e This commit fixes a crash when accessing a math inset. This was due to an invalid CursorSlice::text() null pointer accessed in InsetMathNest::cursorPos():
CoordCache & coord_cache = sl.text()->bv()->coordCache();

As you can see, I used this indirection to access the BufferView::CoordCache(). Bad luck, the passed CursorSlice was not completely valid inside a mathed inset, hence the crash. My solution is to pass BufferView to InsetBase::cursorPos() and all its derivative.

* InsetBase::cursorPos(): pass BufferView const &

* bufferview_funcs::coordOffset(): ditto.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15356 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-17 16:23:27 +00:00
Abdelrazak Younes
52bd213992 More unicode conversion
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15355 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-17 14:46:45 +00:00
Abdelrazak Younes
3a32fff90e Adjust the FIXME texts and Delete commented out setXY() call following Andre comments about it:
The coordcahce is for up/down navigation and vconverting mouseclicks to text positions. It is not for pure display/export which
is what drawT is about. It was a simple oversight not to remove it after some copying from the 'real' draw() method.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15347 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-16 09:08:05 +00:00
Abdelrazak Younes
562d55989a MacOSX compile fix: The class Point conflicted with a struct defined in MacTypes.h.
* coordcache.[Ch]: put everything in the LyX namespace.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15340 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-15 22:32:56 +00:00
Abdelrazak Younes
c7e365365e This commit saves the need to check for lyx::use_gui in a number of places.
* lyx_main.h: define "extern bool lyx::use_gui" here.

* NoGuiFontMetrics.h: new class for command-line LyX

* NoGuiFontLoader.h: new class for command-line LyX

* Application.C:
  - theFontMetrics(): returns the above dummy FontMetrics when use_gui is false.
  - theFontLoader(): returns the above dummy FontLoader when use_gui is false.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15339 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-15 21:47:29 +00:00
Abdelrazak Younes
d0463cf006 Fix command-line export
* MathFactory.C:
  - initMath(): revert change from r15327 because initSymbols() is needed for proper math parsing.
  - math_font_available(): return false if lyx::use_gui is false.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15331 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-14 14:15:06 +00:00
Abdelrazak Younes
dcfd6e5a99 enable buffer-export without loading the GUI.
* lyx_main.C:
  - parse_export(): set lyx::use_gui to false.

* MathFactory.C:
  - initMath(): initSymbols() only if lyx::use_gui is true.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15327 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-13 21:27:55 +00:00
Abdelrazak Younes
d37fae169c In order to support multiple LyXView each BufferView needs its own CoordCache. This is what's implemented in this commit.
theCoords is now a thing of the past and all CoordCache accesses are done via BufferView::coordCache() now. I had to modify a number of methods to pass BufferView.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15324 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-13 16:44:44 +00:00
Georg Baum
79c876d4c3 Convert labels to unicode
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15305 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-12 10:50:45 +00:00
Georg Baum
34b7650cbb Introduce wide streams. This fixes the remaining problems of plain text
export (e.g. the ToC) and the navigate menu.

	* src/insets/insetbase.h
	(InsetBase::plaintext): output to a docstream
	(InsetBase::textString): ditto

	* src/mathed/TextPainter.h
	(TextPainter::show): ditto

	* src/support/docstream.[Ch] New file and string streams for
	docstring. The file streams convert to UTF8 on the fly.

	* many more files: Adjust to the changes above


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15301 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-11 19:40:50 +00:00
Abdelrazak Younes
28ad960255 This commit cleans up everything related to singleton. The other important change is that lyx::dispatch() and lyx::getStatus become _the_ official way to use LyXFunc equivalent methods.
* lyxfunc.h:
  - theLyXFunc(): new function in the global namespace.
  - lyx::dispatch():  new function in the lyx namespace.
  - lyx::getStatus():  new function in the lyx namespace.

* bufferlist.h:
  - theBufferList(): new function in the global namespace.

* Clipboard.h:
  - theClipboard(): new function in the global namespace.

* Selection.h:
  - theSelection(): new function in the global namespace.

* FontLoader.h:
  - theFontLoader(): new function in the global namespace.

* FontMetrics.h:
  - theFontMetrics(LyXFont const &): new function in the global namespace.

* Application.C: implements the functions defined above.

* LyXView.h:
  - getLyXFunc(): deleted.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15298 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-11 17:24:46 +00:00
Jürgen Spitzmüller
05be07de9e Fix bug 2744:
* buffer.[Ch] (changeRefsIfUnique): extend to handle bibitems 
        as well (the function takes a InsetCode argument now);
        clean up by using InsetIterator.

* InsetMathHull.C (doDispatch): changeRefsIfUnique needs a
        InsetCode argument now (bug 2744).

* insetlabel (doDispatch): changeRefsIfUnique needs a
        InsetCode argument now.

* insetbibitem (doDispatch): use changeRefsIfUnique
        (actual fix for bug 2744).

* insetcommand.[Ch]:
* insetcite.[Ch]: implement replaceContents, which is
        used by changeRefsIfUnique.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15289 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-09 14:21:11 +00:00
Abdelrazak Younes
00edcc582f This commit is a big rework of the FontLoader/FontMetrics interaction. Only Qt4 for now, I would be grateful is somebody steps up for qt3 and gtk.
Basically, I replaced all methods in the font_metrics namespace by a proper virtual interface FontMetrics. The FontLoader is _the_ container for FontMetrics.

This patch should also bring some optimizations in a number of place in the code. This is because we do not need any more to search for the LyXFont at each font_metrics call. In effect, the speed advantage is not as sensible and this is a bit deceiving considering that this was my primary motivation behind the patch. But I like the patch anyway as it cleans up the relation and interfacing between fonts, metrics and frontends.

* frontends/FontMetrics.h: new virtual interface. Renamed from font_metrics.h

* qt4/GuiFontMetrics: corresponding qt4 implememtation. Renamed from qfont_metrics.C. The smallCaps particular case treatment has been transfered here as well as the width cache for MacOSX and Windows.

* qt4/QLPainter.C: the smallCapsText has been reworked to return the width of the drawn text.C

all other files: replace font_metric helper function call with corresponding FontMetrics method calls.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15265 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-07 16:15:06 +00:00
Georg Baum
368f6a53a8 Support lgathered and rgathered math environments
* src/mathed/InsetMathSplit.C
	(InsetMathSplit::validate): Only require amsmath for AMS stuff

	* src/mathed/MathFactory.C
	(createInsetMath): create InsetMathSplit if the latexkey is "split"

	* src/mathed/MathParser.C
	(Parser::parse1): remove "gathered" and "aligned", since these are
	now handled via lib/symbols
	(Parser::parse1): create InsetMathSplit if the latexkey is "split"

	* lib/symbols: Add aligned, gathered, lgathered and rgathered


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15224 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 19:45:43 +00:00
Abdelrazak Younes
205096733a This commit introduces the FontLoader interface class. In the future, I intend to extend it with a proper encapsulation of font metrics.
* frontends/FontLoader.h: new interface class.
* frontends/Application.h: new FontLoader() pure virtual method
* frontends/lyx_gui: update_fonts() and font_available() methods deleted

* [qt3/qt4/gtk]/GuiApplication: implement the new interface

* qt4/GuiFontLoader:
  - renamed from FontLoader
  - now derives from FontLoader
  - now in the lyx::frontend namespace

* qt3/qfont_loader
  - now derives from FontLoader

* gtk/xftFontLoader
  - now derives from FontLoader



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15220 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 16:17:32 +00:00
Georg Baum
8fb869e7c6 Missing bits of the std::string -> hullType change of InsetMathHull::type_.
Now we write again \begin{align} instead of \begin{4} to .lyx and .tex.
	* src/mathed/InsetMathHull.C
	(InsetMathHull::header_write): write type name, not type_.
	Use switch instead of if for better readability.
	(InsetMathHull::footer_write): ditto
	(InsetMathHull::mutate): write type name, not type_
	(InsetMathHull::normalize): ditto
	(InsetMathHull::infoize): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15204 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 07:56:27 +00:00
Georg Baum
8a9d0934e9 Parse optional arguments of aligned, gathered and alignedat
* src/mathed/InsetMathSplit.[Ch]
	(InsetMathSplit): Add valignment argument to constructor

	* src/mathed/InsetMathSplit.C
	(InsetMathSplit::write): write vertical alignment if needed

	* src/mathed/MathParser.C
	(Parser::parse1): parse optional arguments of aligned, gathered and
	alignedat


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15202 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-02 20:01:30 +00:00
Georg Baum
deef368edc Fix bug 2789 (as discussed)
* src/mathed/InsetMathHull.C
	(InsetMathHull::doDispatch): move code for ref insert to InsetMathNest 
	(InsetMathHull::getStatus): move code for ref insert to InsetMathNest

	* src/mathed/InsetMathNest.C
	(InsetMathNest::doDispatch): move code from InsetMathHull here
	(InsetMathNest::getStatus): move code from InsetMathHull here


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15189 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-30 17:17:31 +00:00
Abdelrazak Younes
ca5411f913 This commit introduces Application_pimpl and cleanup the header includes of the affected .C files.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15182 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 22:06:28 +00:00
Abdelrazak Younes
0da12b129a delete unneeded BufferView.h declaration.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15159 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 21:11:22 +00:00
Abdelrazak Younes
b171e5f150 Free BufferView from LyXView!
* BufferView
  - layoutChanged: new boost signal.
  - LyXView owner(), owner_: deleted

* text3.C
  - emit BufferView::layoutChanged instead of calling LyXView::setLayout directly
  - LFUN_MOUSE_RELEASE: delete LyXView updateMenubar() and updateToolbars() direct calls.
    The update is of both bars is done in WorkArea::dispatch().

* WorkArea.C
  - dispatch(): add LyXView updateMenubar() call.

* LyXView
  - connects to BufferView::layoutChanged directly to Toolbars::setLayout()
  - setLayout(): deleted.

* qt4/GuiImplementation: modify BufferView construction (without LyXView).

All other files: cleanup header declaration of LyXView.h


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15153 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 10:06:46 +00:00
Abdelrazak Younes
12a82dd4f2 This commit replaces BufferView->LyXView->Gui->[selection,clipboard] with theApp->[selection,clipboard]
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15125 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 15:02:41 +00:00
Abdelrazak Younes
480b4f4fdc This commit replaces BufferView->LyXView->getLyXFunc() with theApp->lyxFunc() and BufferView->LyXView->dispatch() with theApp->lyxFunc().dispatch().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15121 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 14:26:06 +00:00
Abdelrazak Younes
311ac9b192 This is the continuation of my BufferView/LyXView cleanup. This commit replaces BufferView->LyXView->getDialogs().[show(), update()] with BufferView signal emissions.
The associated WorkArea is then responsible to connect these signals to its LyXView parent.

* BufferView:
  - showDialog, showDialogWithData, showInsetDialog: new boost signals

* LyXView:
  - connectBufferView(), disconnectBufferView(): new method in charge of the connection/disconnection of the above signal to associate private methods (showDialog(), etc).

* WorkArea
  - setBufferView(): will connect/disconnect the BufferView to its LyXView parent.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15068 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-19 13:36:20 +00:00
Abdelrazak Younes
1a786c8e17 * Transfer Intl member from LyXView to BufferView.
* delete unused offset_ref() method.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15030 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:03:00 +00:00
André Pönitz
3537aa7448 cleanup after svn hang-up, #undef CursorShape. Should be compilable ganin now.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15029 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:00:15 +00:00
Abdelrazak Younes
14dff4fcb0 compilation fixes
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15028 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 09:55:13 +00:00
André Pönitz
e89625ef28 rename mathed/math_xinset into mathed/InsetMathX
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15026 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 09:14:18 +00:00
André Pönitz
2805c29734 rename Math*Inset into InsetMath*
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15023 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 18:11:38 +00:00
Abdelrazak Younes
a6444784dc A bunch of conversion to docstring.
- bformat(): contributed by Georg Beaum
- Alert::XXX
- error(): in SpellBase, ispell, psell, aspell, buffer, etc.
- message(), message signal
- displayMessage(), setMessage,
- ErrorItems
- prettyName()
- makeDisplayPath()

and maybe some more...


- etc... 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14970 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 08:54:10 +00:00
Lars Gullik Bjønnes
edd81011ce Change editMessage to return a docstring, change functions to not use to_utf8.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14953 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 18:52:00 +00:00
Lars Gullik Bjønnes
43b77ba2d7 Change _() to return a docstring. Fixup callers with the help of lyx::to_utf8.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14952 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 15:27:44 +00:00
Jean-Marc Lasgouttes
45808381d0 Fix bug 2251 (from G Baum)
* src/mathed/math_hullinset.h (displayMargin): new static method.
	* src/mathed/math_hullinset.C (metrics): use displayMargin().

	* src/text2.C (cursorUp, cursorDown): use MathHullInset::displayMargin.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14939 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 13:52:41 +00:00
André Pönitz
3663e1161a use enums instead of strings to distinguish different types of math hull
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14882 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 16:14:51 +00:00
Abdelrazak Younes
35ec954df8 This fixes the crash when PageDown scrolling UserGuide.lyx
* MathMacroTemplate::prefix(): now return docstring.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14876 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 11:54:17 +00:00
Georg Baum
e33bac93cd Fix clipboard/selection encoding
* src/frontends/qt[34]/qt_helpers.[Ch]
	(toqstr): add variant for docstring
	(qstring_to_ucs4): Use docstring and port from qt4 to qt3

	* Many other files: Many std::string -> lyx::docstring conversions

	* src/support/lstrings.[Ch]
	(subst): Add variant for docstring and char_type
	(externalLineEnding): std::string -> lyx::docstring
	(internalLineEnding): std::string -> lyx::docstring


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14871 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 07:02:38 +00:00
Bo Peng
6d23395dc7 Improve Computer Algebra System, from Enrico Forestieri <forenr@tlc.unipr.it>
* src/mathed/math_symbolinset.C
	(void MathSymbolInset::maxima):
	       - newer maxima versions use inf instead of INF
	       - add support for greek pi

	(void MathSymbolInset::mathematica):
	       - add support for \cdot

	* src/mathed/math_stringinset.h
	       - account for the const version of asStringInset()

	* src/mathed/math_extern.C
	(bool extractScript):
	       - added bool superscript to formal parameters in order
	         to only extract superscripts

	(MathArray::iterator extractArgument):
	       - leave out delimiters and a possible superscript
	         for function arguments

	(bool isKnownFunction):
	(bool extractFunctionName):
	       - recognize standard and user defined function names

	(void splitScripts):
	       - correctly split scripts as expected by other functions

	(MathAtom replaceDelims):
	       - ranamed as replaceParenDelims

	(bool testOpenBracket):
	(bool testCloseBracket):
	       - test for "[" and "]", respectively

	(MathAtom replaceBracketDelims):
	       - replace something delimited by "[" and "]" with a
	         proper DelimInset

	(void extractDelims):
	       - create a DelimInset for "[" and "]" delimiters, too

	(void extractFunctions):
	       - improved recognition of function names

	(bool testTermDelimiter):
	       - test for '+' or '-' as term delimiters

	(MathArray::iterator extractTerm):
	       - extract a "term", i.e., something delimited by '+' or '-'

	(bool testDiffItem):
	       - improved recognition of a "differential fraction"

	(void extractDiff):
	       - call splitScripts() on numerator and denominator of a
	         differential fraction before analyzing them

	(void extractLims):
	       - improved recognition of a limit function

	(void extractStructure):
	       - reorganized order of searches

	(MathArray pipeThroughMaxima):
	       - newer versions of maxima use simpsum instead of SIMPSUM

	(string fromMathematicaName):
	       - translates from mathematica names

	(MathArray pipeThroughMathematica):
	       - calls mathematica and collects its output

	(MathArray pipeThroughExtern):
	       - add support for mathematica

	* src/mathed/math_numberinset.C
	* src/mathed/math_numberinset.h
	(void MathNumberInset::mathematica):
	       - add support for mathematica

	* src/mathed/math_matrixinset.C
	* src/mathed/math_matrixinset.h
	(void MathMatrixInset::mathematica):
	       - add support for mathematica

	* src/mathed/math_diffinset.C
	* src/mathed/math_diffinset.h
	(void MathDiffInset::maxima):
	       - add support for maxima

	(void MathDiffInset::mathematica):
	       - mathematica uses "D" and not "Dt" for normal derivatives

	* src/mathed/math_liminset.C
	* src/mathed/math_liminset.h
	(void MathLimInset::maxima):
	       - add support for maxima

	(void MathLimInset::mathematica):
	       - mathematica uses "Limit" and not "Lim" for limits

	* src/mathed/math_exfuncinset.C
	(string asMathematicaName):
	       - added some more function names


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14865 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-02 01:57:36 +00:00
Georg Baum
1fc0c01877 convert lfun arguments to docstring
* src/support/docstring.[Ch]
	(from_ascii): new conversion function
	(from_utf8): new conversion function
	(to_utf8): new conversion function
	(operator==) new, compare docstring and ASCII C string
	(operator!=) new, compare docstring and ASCII C string

	* src/support/Makefile.am: add new file docstring.C

	* development/scons/scons_manifest.py: ditto

	* src/funcrequest.[Ch]
	(argument): change name to argument_ and type to docstring,
	add an accessor
	(FuncRequest): Add two new constructors taking a docstring argument

	* all other files: adjust to the FuncRequest changes above


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14861 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-01 15:41:38 +00:00
Jean-Marc Lasgouttes
b4d20b81af Handle properly script insets which nucleus has more than one
element (like {a'}^{2}). (froward port from 14802)

	* src/mathed/math_nestinset.C (script): when creating a script
	inset, handle specially previous atom if it is a MathBraceInset
	(this is used in interactive input).

	* src/mathed/math_parser.C (parse1): when creating a script inset,
	handle specially previous atom if it is a MathBraceInset (this is
	used in parsing phase).

	* src/mathed/math_scriptinset.C (write): put nucleus into braces
	if it contains more than one element or is itself a script inset.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14819 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-23 10:57:49 +00:00
Michael Schmitt
b124158c34 drop linuxdoc support (part 3)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14818 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-23 10:57:45 +00:00
Jean-Marc Lasgouttes
c9b50bc70e * math_nestinset.C (lfunMousePress): on button 2 press, paste
inner LyX selection if it exists (bug 2779).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14812 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-22 13:58:09 +00:00
Jean-Marc Lasgouttes
020a793ef9 Fix crash when cursor is in an empty script and the user clicks
in the text.

	* src/insets/insetbase.h (notifyCursorLeaves): return a bool
	indicating whether cursor is invalidated.

	* src/mathed/math_nestinset.C (notifyCursorLeaves): 
	* src/mathed/math_hullinset.C (notifyCursorLeaves): adapt to
	prototype change.

	* src/mathed/math_scriptinset.[Ch] (notifyCursorLeaves): return
	true when an inset has been deleted.

	* src/BufferView.C (mouseSetCursor): do not call dEPM when cursor
	is invalidated by notifyCursorLeaves.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14796 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-17 21:32:04 +00:00
Jean-Marc Lasgouttes
4d55c8b288 Fix bug 2727.
* math_scriptinset.C (notifyCursorLeaves): call recordUndoInset
	before deleting a cell; if the nucleus does not have scripts
	anymore, delete it and replace it by its contents at enclosing
	level. 
	(write): output scripts even when they are empry.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14793 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-17 21:07:24 +00:00
Jean-Marc Lasgouttes
f46a3db4d8 fix bad debug messages
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14784 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-17 13:23:08 +00:00
Lars Gullik Bjønnes
c46b7d8955 Merge the unicode branch into trunk.
- src/support/unicode.[Ch]: new files with functions for converting
  to and fro ucs4, ucs2 and utf8.
- src/support/docstring.h: specialization of basic_string that
  holds a uint32_t internally.
- Several functions changed to use char_type instead of char or unsigned char.
- Qt3 and Qt4 sends ucs2 on to core
- Gtk sends ucs4 on to core
- Read and write utf-8 .lyx files.
- font_metrics and painter updated to handle ucs4 chars as input.
- Quite a bit of ugly compability code, conversion string->docstring, etc.
- Have fun...


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14661 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-13 22:54:59 +00:00
Jean-Marc Lasgouttes
9c7696c6ee Fix bug 2756:
* src/BufferView_pimpl.C (dispatch/LFUN_NEXT_INSET_TOGGLE): moved from
	LyXText.

	* src/text3.C (dispatch/LFUN_NEXT_INSET_TOGGLE): moved to
	BufferView::Pimpl, since this should work in mathed too.

	* src/mathed/math_nestinset.C (doDispatch/LFUN_INSET_TOGGLE): do not try to
	do the work which belongs to LFUN_NEXT_INSET_TOGGLE (bug 2756).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14617 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-11 21:41:56 +00:00
Jean-Marc Lasgouttes
8bbbfcc056 yet another annoying debug message bites the dust
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14586 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-08 22:17:13 +00:00
Jean-Marc Lasgouttes
5e0c737a3b * src/mathed/math_scriptinset.C
(MathScriptInset::hasLimits): remove annoying debug message

	* src/mathed/math_nestinset.C
	(MathNestInset::script): ditto

	* src/CutAndPaste.C
	(copySelection): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14583 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-08 21:55:41 +00:00
Georg Baum
096a05206a shut up compiler warning message
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14529 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-31 17:44:50 +00:00
Georg Baum
117c98c416 Fix read in of \over (related to bug 2481)
* src/mathed/math_factory.C
        (createMathInset): Create a MathFracInset of kind OVER for \over

        * src/mathed/math_fracinset.C
        (MathFracInset::draw): handle kind OVER
        (MathFracInset::drawT): ditto
        (MathFracInset::write): ditto
        (MathFracInset::name): ditto
        (MathFracInset::extraBraces): ditto

        * src/mathed/math_fracinset.h
        (Kind): New kind OVER


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14487 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-19 10:50:18 +00:00
Georg Baum
921f1144cc Fix bug 2481
* src/mathed/math_fracinset.[Ch]
	(MathFracInset::extraBraces): new, return true for \atop
	* src/mathed/math_binominset.[Ch]
	(MathBinomInset::extraBraces): new, return true for \choose


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14470 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-16 17:19:05 +00:00
Michael Schmitt
bc1582b0b1 remove LFUN_INSET_DIALOG_SHOW
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14450 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-14 08:11:23 +00:00
Georg Baum
c9c6ed0b7f Split clipboard and X selection
* src/LyXAction.C
	(LyXAction::init): handle new LFUN_CLIPBOARD_PASTE

	* src/insets/insettabular.C
	(InsetTabular::doDispatch): ditto

	* src/insets/insetbox.C
	(InsetBox::doDispatch): ditto

	* src/insets/insetert.C
	(InsetERT::doDispatch): ditto
	(InsetERT::getStatus): ditto

	* src/insets/insetcharstyle.C
	(InsetCharStyle::doDispatch): ditto

	* src/BufferView_pimpl.C
	(BufferView::Pimpl::selectionRequest): stuff selection, not clipboard

	* src/mathed/math_nestinset.C
	(MathNestInset::lfunMousePress): get stuff selection, not clipboard
	(MathNestInset::lfunMouseRelease): clipboard -> selection in
	commented code

	* src/CutAndPaste.C
	(cutSelection): ditto

	* src/frontends/{qt3,gtk}/GuiImplementation.C
	(GuiImplementation::newWorkArea): create new selection, not clipboard,
	since the clipboard is now an object
	(GuiImplementation::destroyWorkArea): destroy selection, not clipboard

	* src/frontends/{qt4,qt3,gtk}/GuiSelection.h: new, copied from
	GuiClipboard.h

	* src/frontends/{qt4,qt3,gtk}/GuiSelection.C: new, copied from
	GuiClipboard.C

	* src/frontends/{qt3,gtk}/GuiImplementation.h
	(selection): new accessor for selection_
	(selection_): new, the global selection object

	* src/frontends/{qt4,qt3,gtk}/Makefile.am: add GuiSelection.C and
	GuiSelection.h

	* src/frontends/{qt4,qt3,gtk}/GuiClipboard.C
	(GuiClipboard::get): return clipboard, not selection
	(GuiClipboard::put): stuff clipboard, not selection

	* src/frontends/{qt4,qt3,gtk}/GuiClipboard.h
	(haveSelection): remove (this is now in GuiSelection)

	* src/frontends/{qt3,gtk}/GuiClipboard.h
	(old_work_area_): remove, since it is not needed anymore

	* src/frontends/gtk/ghelpers.C
	(getGTKStockIcon): handle LFUN_CLIPBOARD_PASTE

	* src/frontends/Clipboard.h
	(haveSelection): remove (this is now in Selection)

	* src/frontends/qt4/GuiImplementation.[Ch]
	(GuiImplementation::selection): new accessor for selection_

	* src/frontends/Gui.h
	(selection): New accessor for the global selection object

	* src/frontends/Selection.h; new, copied from Clipboard.h

	* src/frontends/Makefile.am: add Selection.h

	* src/text3.C
	(various): s/clipboard().haveSelection/selection().haveSelection/

	(LyXText::dispatch): handle LFUN_CLIPBOARD_PASTE
	(LyXText::getStatus): ditto

	* src/lfuns.h: new lfun LFUN_CLIPBOARD_PASTE

	* lib/ui/stdmenus.ui: add new lfun LFUN_CLIPBOARD_PASTE


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14408 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-10 11:32:25 +00:00
Abdelrazak Younes
6dd6b5b22a initialize member variables: width_, scriptable_
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14401 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-09 16:35:20 +00:00
Lars Gullik Bjønnes
1afb2a6b05 Remove quite a few compiler warnings:
- Change unsigned -> signed
	- Change signed -> unsigned
        - Add a cast or two (really few of those)
	- Remove/comment out unused variables
	- Comment out unused arguments
	- Add missing cases to switches.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14344 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-06 08:18:51 +00:00
Lars Gullik Bjønnes
fb97c0689b First part of r14315 from the younes branch:
* BufferView and BufferView::pimpl:
   		- getClipboard, stuffClipboard, haveSelection: deleted

	* CutAndPaste.C: use BufferView::owner()->gui().clipboard()
	* insettabular.C: ditto
	* math_nestinset.C: ditto
	* text3.C: ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14323 a592a061-630c-0410-9148-cb99ea01b6c8
2006-07-03 20:19:33 +00:00
Georg Baum
254b3cf67c Fix limit display of intop and ointop
* src/mathed/math_scriptinset.C
	(MathScriptInset::hasLimits): handle \intop and \ointop

	* lib/symbols: add intop and ointop


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14225 a592a061-630c-0410-9148-cb99ea01b6c8
2006-06-26 15:01:35 +00:00
Georg Baum
331e78d3e0 revert last accidental commit and do the intended one
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14186 a592a061-630c-0410-9148-cb99ea01b6c8
2006-06-23 14:20:49 +00:00
Georg Baum
390ea4eb24 * src/mathed/math_gridinset.C
(doDispatch): fix off by one error when checking cur.idx() (bug 2655)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14185 a592a061-630c-0410-9148-cb99ea01b6c8
2006-06-23 14:17:14 +00:00
Abdelrazak Younes
d8ae51dbe1 This is the merging of the GUI API cleanup branch that was developed in svn+ssh://svn.lyx.org/lyx/lyx-devel/branches/personal/younes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14152 a592a061-630c-0410-9148-cb99ea01b6c8
2006-06-20 08:39:16 +00:00
Jean-Marc Lasgouttes
00b9544ddc * src/mathed/math_hullinset.h (canTrackChanges): remove, since math insets do
not implement (yet) change tracking.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13867 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-18 21:08:11 +00:00
Lars Gullik Bjønnes
5e3b997b85 Remove the now superseeded SConscript files, and some small missing parts to SConstruct
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13825 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-10 18:05:12 +00:00
Michael Schmitt
1396ade8b1 fix LFUN enum values (some of them were broken by r13801)
adjust some commands according to the LyX naming conventions
(toggle-tooltip => tooltip-toggle, *-change(s) => change(s)-*) 


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13811 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-08 18:09:19 +00:00
Bo Peng
7168ce58b5 scons-based build system, by Bo Peng (ben.bob@gmail.com)
* SConstruct: main SConstruct file
	* scons_utils.py: utility functions
	* qt4.py: qt4 support is not yet official, and I have to patch this file
	* src/SConscript
	* src/insets/SConscript
	* src/graphics/SConscript
	* src/mathed/SConscript
	* src/frontends/qt3/SConscript
	* src/frontends/qt4/SConscript
	* src/frontends/SConscript
	* src/frontends/controllers/SConscript
	* src/support/SConscript
	* src/client/SConscript
	* src/tex2lyx/SConscript
	* boost/libs/SConscript
	* boost/libs/signals/src/SConscript
	* boost/libs/filesystem/src/SConscript
	* boost/libs/iostreams/src/SConscript
	* boost/libs/regex/src/SConscript


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13807 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-07 22:44:54 +00:00
Georg Baum
b6c3478eda Implement GUI for fixed size math delimiters (by Enrico Forestieri and me):
* src/lfuns.h
	(enum kb_action): New lfun LFUN_MATH_BIGDELIM

	* src/LyXAction.C
	(void LyXAction::init): New lfun LFUN_MATH_BIGDELIM

	* src/mathed/math_nestinset.C
	(void MathNestInset::doDispatch): remove debug message
	(void MathNestInset::doDispatch): remove LFUN_MATH_DELIM test for
	multiple cells (now in getStatus)
	(void MathNestInset::doDispatch): Handle LFUN_MATH_BIGDELIM
	(bool MathNestInset::getStatus): Disable LFUN_MATH_DELIM and
	LFUN_MATH_BIGDELIM when the selection spans multiple cells

	* src/frontends/qt3/ui/QDelimiterDialogBase.ui
	Added a combobox for selecting delimiter size.

	* src/frontends/qt3/QDelimiterDialog.[Ch]
	(fix_name, QDelimiterDialog, insertClicked, size_selected):
	Allow for fixed size delimiters.

	* src/frontends/gtk/GMathDelim.C: Add FIXME commnent for fixed size
	delimiters
	* src/frontends/qt4/QDelimiterDialog.C: ditto
	* src/frontends/xforms/FormMathsDelim.C: ditto

	* src/frontends/controllers/ControlMath.[Ch]:
	Added dispatchBigDelim() to deal with fixed size delimiters.

	* src/text3.C
	(void LyXText::dispatch): Handle LFUN_MATH_BIGDELIM
	(bool LyXText::getStatus): ditto

	* src/ToolbarBackend.C
	(string const ToolbarBackend::getIcon): Handle LFUN_MATH_BIGDELIM


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13806 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-07 10:51:19 +00:00
André Pönitz
da65e2b7fb rename LFUN enum values according to their command (as used in th minibuffer/bind files
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13801 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-05 20:23:12 +00:00
Georg Baum
143e14045f Code cleanup of \bigl related stuff:
* src/cursor.C
	(LCursor::plainInsert): Move special \bigl stuff from here to
	MathNestInset::interpret
	(LCursor::macroModeClose): try to intepret the current macro before
	it is simply inserted

	* src/mathed/math_nestinset.C
	(MathNestInset::doDispatch): try to intepret the argument of
	LFUN_SELFINSERT also if it is longer than one character

	* src/mathed/math_nestinset.[Ch]
	(MathNestInset::interpret): new, moved from LCursor::plainInsert


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13786 a592a061-630c-0410-9148-cb99ea01b6c8
2006-05-01 08:05:22 +00:00
Georg Baum
850346d996 * src/mathed/math_biginset.[Ch]
(infoize2): Implement to show name if the cursor is to the right


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13757 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-27 07:55:25 +00:00
Georg Baum
2bbe7e5b89 Make MathBigInset working
* src/cursor.C
        (LCursor::plainInsert): combine the previous math atom with the new
        one to a MathBigInset if possible

        * src/mathed/math_biginset.[Ch]
        (MathBigInset::name): implement
        (MathBigInset::isBigInsetDelim): new, test whether a given token is
        a valid MathBigInset delimiter

        * src/mathed/math_biginset.C
        (MathBigInset::size): handle Big, Bigg and Biggg
        (MathBigInset::increase): ditto
        (MathBigInset::draw): fix deco drawing
        (MathBigInset::write): append space if necessary

        * src/mathed/math_factory.C
        (createMathInset): handle l->inset == "big"

        * src/mathed/math_parser.C
        (Token::asInput): return a token as input, stolen from tex2lyx
        (void Parser::parse1): Create a MathBigInset when needed

	* src/mathed/math_support.C:
	(deco_table): add lbrace and rbrace

        * src/mathed/math_nestinset.C
        (MathNestInset::interpret): combine the previous math atom with the
        new character to a MathBigInset if possible

        * src/ParagraphParameters.C
        (findToken): move from here

        * src/support/lstrings.[Ch]
        (findToken): to here

        * lib/symbols: add MathBigInset symbols


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13700 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-20 09:55:45 +00:00
Georg Baum
3072b1111e Implement \phantom, \hphantom and \vphantom in math (bug 1473):
* src/mathed/math_factory.C
	(createMathInset): handle \phantom, \hphantom and \vphantom
	* src/mathed/Makefile.am: add math_phantominset.[Ch]
	* src/mathed/math_phantominset.[Ch]: new phantom inset


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13680 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-15 09:54:24 +00:00
Jürgen Spitzmüller
786a8e1ab8 * src/LaTeXFeatures.C
(char const * simplefeatures[]): add tipa

        * src/mathed/math_fontinset.C
        (void MathFontInset::validate): textipa requires tipa


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13677 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-14 14:30:43 +00:00
Jean-Marc Lasgouttes
2fcae62a4d * math_xarrowinset.C (validate):
* math_splitinset.C (validate): new methods; require amsmath (bug
	2149).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13662 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-13 10:31:32 +00:00
Martin Vermeer
7db0b5ae00 * math_nestinset.C
(MathNestInset::doDispatch): replace recordUndo by recordUndoInset for
	LFUN_DELETE, to fix undo behaviour



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13658 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-13 08:40:11 +00:00
Georg Baum
e8ec07a066 fix bug 2036:
* src/mathed/math_amsarrayinset.C
	(metrics): use ArrayChanger to change the style
	(draw): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13648 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-11 13:57:05 +00:00
Martin Vermeer
e6c2e24dc8 Undo previous
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13619 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-10 11:04:20 +00:00
Martin Vermeer
df09c79544 Fix bug 2485 and crash on middle-mouse paste into math.
Also move reponse to middle mouse from Release to Press

        * math_nestinset.C
        (MathNestInset::lfunMousePress): Add and convert to editXY
        (MathNestInset::lfunMouseRelease): Remove


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13617 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-10 10:47:59 +00:00
Martin Vermeer
e977a3e509 Fix bug 2485 and crash on middle mouse paste on math
* math_nestinset.C
	(MathNestInset::lfunMousePress): handle middle mouse here, use
	editXY, not setScreenPos
	(MathNestInset::lfunMouseRelease): don't handle here



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13612 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-09 07:06:57 +00:00
Lars Gullik Bjønnes
8c93f63b48 * filetools.[Ch]: Make functions that start with a capital
letter start with a lower letter.
	* All other .C and .h in the cs: adjust for above change


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13603 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-08 22:31:11 +00:00
Martin Vermeer
9e6c3bd7c2 The nicefrac patch
* LaTeXFeatures.C
	(simplefeatures[]: add nicefrac

	* mathed/math_factory.C
	(createMathInset): change frac semantics

	* mathed/math_fracinset.[Ch]

	(MathFracInset::metrics):
	(MathFracInset::draw):
	(MathFracInset::drawT):
	(MathFracInset::write):
	(MathFracInset::mathmlize): add nicefrac stuff

	* mathed/math_dfracinset.C:
	* mathed/math_tfracinset.C: adapt semantics

	* frontends/qt2/ui/QMathDialogBase.ui

	* frontends/qt2/QMathDialog.[Ch]
	(QMathDialog::symbol_clicked): provide GUI



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13566 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-06 09:46:01 +00:00
Lars Gullik Bjønnes
3b9338a3a8 Whitespace cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13565 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-05 23:56:29 +00:00
Martin Vermeer
cc91bd643f * math_gridinset.C (MathGridInset::doDispatch): reset cur.pos() when
deleting current col or row



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13450 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-22 08:46:54 +00:00
Martin Vermeer
206e3745a2 Further revision of the raise/lower selection to super/subscript
patch, avoiding class data member for nestinset

	* cursor.h: remove paste() (was forgotten)
	* mathed/math_nestinset.C
	(MathNestInset::doDispatch):
	(MathNestInset::lfunMouseRelease): 
	(MathNestInset::interpret): incorporate saved selection into
	script() call parameters
	(MathNestInset::script): saved selection is extra parameter
	* mathed/math_nestinset.h: extra parameter; remove safe_



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13431 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-20 14:42:04 +00:00
Martin Vermeer
0a57bcafeb * math_nestinset.C
(MathNestInset::doDispatch): fix bug 2345: C-M on text in math gives
	an empty mbox



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13425 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-20 08:42:43 +00:00
Martin Vermeer
2c30e9b17a Get raising/lowering into super/subscripts of selection working (1.3
regression)

	* cursor.C: get rid of paste()

	* mathed/math_nestinset.C
	(MathNestInset::doDispatch):
	(MathNestInset::lfunMouseRelease): define safe_ (selection) in
	several places
	(MathNestInset::script): use data member safe_ to insert selection

	* mathed/math_nestinset.h: data member safe_



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13424 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-20 06:53:29 +00:00
Martin Vermeer
3d0c878966 Changes to the within-inset row rendering caching code.
* insets/insetenv.h: 
	* insets/insetcollapsable.h: remove method
	* insets/insettabular.h:
	* insets/insetbase.h: rename, add methods
	* insets/insettext.[Ch]: rename method; add Tall()
	* paragraph_pimpl.C
	(Paragraph::Pimpl::simpleTeXSpecialC): rename call
	* mathed/math_hullinset.h: rename method
	* rowpainter.C
	(RowPainter::paintInset):
	(paintPar): remove isTrueTextInset, move to insets 



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13415 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-17 19:45:28 +00:00
Georg Baum
fad5cd6700 fix bug 2234
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13399 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-16 15:05:47 +00:00
Martin Vermeer
b751c74fe1 Fix to bug 2325: Mouse click to right of last nestinset in a cell will
position cursor to its left



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13370 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-14 14:47:24 +00:00
Martin Vermeer
2ebd47ea30 Fix to bug 2362: Deleting superscript also deletes subscript.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13342 a592a061-630c-0410-9148-cb99ea01b6c8
2006-03-11 16:34:52 +00:00
Martin Vermeer
786c079b89 fix (properly) insertion of fonts/decorations around selection
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13280 a592a061-630c-0410-9148-cb99ea01b6c8
2006-02-28 19:16:38 +00:00
Jean-Marc Lasgouttes
498a451a76 bug 1918: Positioning cursor in mathinset with the mouse does not work correctly (and can crash)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13275 a592a061-630c-0410-9148-cb99ea01b6c8
2006-02-24 14:41:48 +00:00
Georg Baum
2535ea14bd readd xymatrix inset (bug 2238)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13265 a592a061-630c-0410-9148-cb99ea01b6c8
2006-02-22 12:26:06 +00:00
Jean-Marc Lasgouttes
7bb1fa55ac bug 2060: Clicking on a macro in a math inset crashes LyX
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13235 a592a061-630c-0410-9148-cb99ea01b6c8
2006-02-14 10:41:34 +00:00
Lars Gullik Bjønnes
4a7ab830bc Delete all .cvsignore files from trunk
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13208 a592a061-630c-0410-9148-cb99ea01b6c8
2006-02-10 22:09:45 +00:00
Lars Gullik Bjønnes
a30c5b2502 get rid of a compiler warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10793 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-28 22:15:47 +00:00
Jean-Marc Lasgouttes
0b281dcea7 fix bug 1934
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10781 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-27 22:24:37 +00:00
Jean-Marc Lasgouttes
f687620a13 fix reading of math macros when they occur before any formula
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10770 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-24 11:04:30 +00:00
Jean-Marc Lasgouttes
1b411d8e9c fix bug 2034
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10726 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-11 17:08:50 +00:00
Martin Vermeer
492f394571 Fix default label setting (eq:)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10719 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-10 12:49:34 +00:00
Lars Gullik Bjønnes
cfcb59904b fix some syntax errors
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10695 a592a061-630c-0410-9148-cb99ea01b6c8
2006-01-01 20:28:05 +00:00
Jürgen Spitzmüller
ee8b2830f1 Move initMath() from startup to math_hullinset. LyX should now start significantly faster for people with lots of fonts.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10661 a592a061-630c-0410-9148-cb99ea01b6c8
2005-12-15 16:59:59 +00:00
Jürgen Spitzmüller
6a36d26356 fix bug 2139 (creation of two consecutives, but different script insets)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10641 a592a061-630c-0410-9148-cb99ea01b6c8
2005-12-02 06:34:19 +00:00
Jean-Marc Lasgouttes
3246cc9a4a bug 2109: trigger dEPM when moving cursor with mouse
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10637 a592a061-630c-0410-9148-cb99ea01b6c8
2005-12-01 10:28:50 +00:00
Martin Vermeer
1b8589e214 Fix bug 2117: matrix inside delimiters or sub/superscript
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10624 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-28 10:23:19 +00:00
Jürgen Spitzmüller
d9e6e32961 fix bug 2089: Touching Navigate menu crashes Lyx when a TOC inset is in a section layout
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10622 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-25 14:40:34 +00:00
Georg Baum
2fdc606248 fix bug 2126 (references in math)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10616 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-22 13:52:25 +00:00
Georg Baum
5be7e73fde don't dereference invalid iterators
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10596 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-08 15:12:05 +00:00
Angus Leeming
d9f29afe1c Trivial fixes to some warnings thrown up by MSVS.Net 2003.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10585 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-02 20:11:36 +00:00
Martin Vermeer
b82859b382 Fix bug 2074: kern width wrong
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10583 a592a061-630c-0410-9148-cb99ea01b6c8
2005-11-02 12:57:47 +00:00
Georg Baum
4341a88656 fix bug 2067
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10553 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-14 10:50:23 +00:00
Georg Baum
d7055d0a8e implement missing bits of math cut and paste and fix bug 2059
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10548 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-12 18:44:53 +00:00
Georg Baum
a2b40d9038 fix invalid cursor after math undo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10547 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-12 18:40:22 +00:00
Georg Baum
7c67a37f53 fix bug 2060
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10525 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-05 21:19:32 +00:00
Jean-Marc Lasgouttes
609e7ae488 fix bug 2057: Delete key acting unexpectedly in MathEd
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10515 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-03 12:22:19 +00:00
Georg Baum
aebef8f685 fix bug 2050
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10514 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-03 12:16:34 +00:00
Jürgen Spitzmüller
66d2b93f7c fix bug 2058 (crash when undoing math matrix delete)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10510 a592a061-630c-0410-9148-cb99ea01b6c8
2005-10-03 09:50:28 +00:00
Jürgen Spitzmüller
cc4af55608 leave inset to the right when hitting ESC (bug 2034)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10488 a592a061-630c-0410-9148-cb99ea01b6c8
2005-09-27 08:42:28 +00:00
Jürgen Spitzmüller
97ca98f0b7 make LFUN_CUT in mathed undoable (bug 2041)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10485 a592a061-630c-0410-9148-cb99ea01b6c8
2005-09-26 11:14:59 +00:00
Jürgen Spitzmüller
65224675ce add nested math insets to the coord cache (fixes the major part of bug 1918).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10484 a592a061-630c-0410-9148-cb99ea01b6c8
2005-09-26 10:34:24 +00:00
Jean-Marc Lasgouttes
81efcd9cf6 fix compiler warnings (bug 1927)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10465 a592a061-630c-0410-9148-cb99ea01b6c8
2005-09-20 08:31:37 +00:00
Jürgen Spitzmüller
dea6e50734 fix bug 1960 and bug 1981 properly, using cur.normalize()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10457 a592a061-630c-0410-9148-cb99ea01b6c8
2005-09-19 09:57:04 +00:00
Martin Vermeer
16e093636f Fix bug 1981
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10399 a592a061-630c-0410-9148-cb99ea01b6c8
2005-08-19 12:57:47 +00:00
Georg Baum
8a81176114 fix bug 1942
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10357 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-26 14:28:45 +00:00
André Pönitz
f70191cc10 some (yet unfinished) up/down work
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10333 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-18 17:12:28 +00:00
André Pönitz
af5acb6dc7 ~4% speedup by inlining a few one-line accessors
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10320 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-18 11:00:15 +00:00
Angus Leeming
7704aa9055 Help Lars spell his name.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10311 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-18 08:04:50 +00:00
André Pönitz
3410c395b5 Andreas' patch to prevent crash on click on previewd inset
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10309 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-18 00:45:10 +00:00
André Pönitz
6d8d1f3d62 reenable TAB and S-TAB in math, fixing a regression against 1.3
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10307 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-18 00:09:20 +00:00
André Pönitz
3e1919e067 probably fixed bug 1561
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10298 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-17 23:03:01 +00:00
André Pönitz
7672118199 use the real label dialog in math as well
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10295 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-17 16:36:21 +00:00
André Pönitz
a2e8af4509 remove files that have not been used since two years
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10271 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-17 10:36:19 +00:00
André Pönitz
6b14cbd9c4 cosmetics, incidently fixing bug 1458
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10270 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-17 10:31:44 +00:00
André Pönitz
008dad0e3a clean up
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10265 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-17 01:13:36 +00:00
André Pönitz
6d8ce8c308 fix old off-by-one bug resulting in a coordcache assert
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10256 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-16 17:55:49 +00:00
André Pönitz
282f86fbb1 send UpdatableInset down the way of the Dodo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10228 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 22:10:25 +00:00
André Pönitz
0411671a57 Stephan's patch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10223 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 16:52:27 +00:00
André Pönitz
41ecabf519 make boundary property an iterator property instead of a CursorSlice property
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10214 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 15:49:40 +00:00
Jean-Marc Lasgouttes
eec58249c4 From Stephan: do not allow insert of label for inlined eq
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10210 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 15:19:07 +00:00
André Pönitz
83c44ca6e7 fix typo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10202 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 10:12:29 +00:00
André Pönitz
97a158fd8e small cosmetic fix and removing some debug output
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10198 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 08:51:34 +00:00
André Pönitz
1a9992c796 partial fix for bug 622, cosmetic rest remains open
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10195 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-15 00:39:44 +00:00
André Pönitz
ec5265b97c Fix bug 1472
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10193 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-14 23:36:49 +00:00
André Pönitz
6152c4abcc fix #1729
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10191 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-14 22:41:59 +00:00
André Pönitz
275f6172ac open insets when selection is set there
to avoid crashs with cold coord cache


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10188 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-14 17:30:24 +00:00
André Pönitz
de70b1ce26 handle LFUN_ESCAPE properly in math insets (i.e. go up one level of
nesting)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10184 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-14 14:48:46 +00:00
André Pönitz
8120816f1a cursor should not get stuck on page up/down in math
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10181 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-14 11:54:45 +00:00
Lars Gullik Bjønnes
a78c91bdbb make sure to dist pch.h and mark PCH_FILE as a built file
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10173 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-12 23:42:23 +00:00
Georg Baum
14d7a4424e add forgotten comment about jumping cursor
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10161 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-10 09:30:07 +00:00
Georg Baum
e87254ab12 fix undo in grids
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10149 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-08 09:12:34 +00:00
Georg Baum
7fdf13d545 Don't store row and col in cursor, add some documentation about idx
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10135 a592a061-630c-0410-9148-cb99ea01b6c8
2005-07-06 07:28:16 +00:00
Martin Vermeer
883decc7da Fix the assert when copying rows or columns in math.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10114 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-30 18:02:39 +00:00
Jürgen Spitzmüller
2368acd8c0 fix {super|sub}script via menu (bug 1667)
fix font attribute handling in mathed text mode


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10100 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-24 10:14:33 +00:00
Georg Baum
99ac9d8dda require amsmath for \text
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10098 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-24 08:25:33 +00:00
Georg Baum
02ab1bf675 fix math color inset UI and parsing
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10083 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-17 14:35:19 +00:00
Jean-Marc Lasgouttes
a95ef64241 fix warning when assertions are disabled
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10032 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-09 12:17:50 +00:00
Angus Leeming
70572847e2 Whitespace, only whitespace. s/ +$//
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10024 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-09 09:58:08 +00:00