Commit Graph

15 Commits

Author SHA1 Message Date
Dov Feldstern
cd95a4bae8 Getting rid of LTR bias --- part 4/4
This is the final patch (at least for now). This one deals with the idxFoo
methods in the math insets. The previous patches in the series are r21128, 
r21244 and r21448.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21449 a592a061-630c-0410-9148-cb99ea01b6c8
2007-11-05 19:44:03 +00:00
Dov Feldstern
ddd82f7aa4 Getting rid of LTR bias --- part 3/4
This is a continuation of r21128, r21244


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21448 a592a061-630c-0410-9148-cb99ea01b6c8
2007-11-05 19:41:16 +00:00
Abdelrazak Younes
f319fdbc2a Put MathData on a diet: transfer dimension cache to BufferView' CoordCache along its position.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20465 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-24 13:52:04 +00:00
Abdelrazak Younes
137158532b Put mathed on a diet: transfer dimension cache from inset to BufferView.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20457 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-23 22:39:49 +00:00
Abdelrazak Younes
237c132c1e * Inset:
- get rid of the cached Dimension. Text inset dimensions are saved in ParagraphMetrics and mathed maintain their own dimension where needed.
- width(), ascent(), descent(): deleted.
- dimension(): now needs a valid BufferView.
- metrics(): now void.

* BufferView::getCoveringInset(): simplify.

* ParagraphMetrics(): now cache inset dimensions.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20420 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-21 20:39:47 +00:00
André Pönitz
ed858d73e5 use bald pointers in clone()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19920 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 18:03:17 +00:00
André Pönitz
32871c1284 rename InsetBase to Inset
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18089 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 13:39:47 +00:00
André Pönitz
31059d1741 rename MathArray into MathData
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18043 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 16:05:57 +00:00
André Pönitz
42123ab8a7 rename LCursor->Cursor
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18040 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 14:56:30 +00:00
Enrico Forestieri
5b2d7ec76d Account for real width of nucleus when positioning superscripts in mathed
* src/mathed/MathSupport.[Ch]
	(mathed_char_kerning): New. Compute right kerning for the given
	font and character as the difference between right bearing and
	logical width.

	* src/mathed/InsetMathScript.[Ch]
	(InsetMathScript::dx1, InsetMathScript::metrics): Account for
	nucleus right kerning.
	(InsetMathScript::nker): New. Return the nucleus right kerning
	if positive, zero otherwise.

	* src/mathed/MathData.[Ch]
	(MathArray::metrics): Cache the nucleus right kerning value.
	(MathArray::kerning): New. Return cached right kerning.

	* src/mathed/InsetMathChar.[Ch]
	(InsetMathChar::metrics): Cache the character right kerning.
	(InsetMathChar::kerning): New. Return cached right kerning.

	* src/mathed/InsetMath.h
	(InsetMath::kerning): New virtual method.

	* src/mathed/InsetMathSymbol.[Ch]
	(InsetMathSymbol::metrics): Cache the symbol right kerning.
	(InsetMathSymbol::kerning): New. Return cached right kerning.

	* src/mathed/InsetMathFont.[Ch]
	(InsetMathFont::kerning): New. Return cached right kerning.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17497 a592a061-630c-0410-9148-cb99ea01b6c8
2007-03-21 17:21:59 +00:00
Enrico Forestieri
54cd34f60b Fig bug 3335 (http://bugzilla.lyx.org/show_bug.cgi?id=3335)
* src/mathed/InsetMathScript.[Ch]
	(InsetMathScript::dy01): new, jointly account for both superscript
	and subscript according to the rules in Appendix G of the TeXbook.
	(InsetMathScript::dy0, InsetMathScript::dy1): set ascent and descent
	values using dy01 for non-limits super/subscripts.
	(InsetMathScript::metrics): account for the new super/subscript
	placement rules when setting ascent and descent values.

	* src/mathed/MathData.[Ch]
	(MathArray::metrics): cache parameters needed for super/subscript
	placement. When nucleus is not empty, set its ascent value to zero
	such that it is correctly computed later, otherwise ascent values
	less than that of an 'I' are not reported.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17471 a592a061-630c-0410-9148-cb99ea01b6c8
2007-03-18 15:00:57 +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
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
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
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