mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-13 09:15:50 +00:00
bug 814
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_1_3_X@6061 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
25e088d6db
commit
3dc6bc5900
@ -1,3 +1,9 @@
|
||||
2003-02-07 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
|
||||
|
||||
* text.C (getLengthMarkerHeight):
|
||||
(drawLengthMarker): make the `symbolic' lengths (small/med/big)
|
||||
visible on screen too.
|
||||
|
||||
2003-02-05 Angus Leeming <leeming@lyx.org>
|
||||
|
||||
* lyxserver.C (read_ready): revert my patch of 11 September last year
|
||||
|
26
src/text.C
26
src/text.C
@ -3235,13 +3235,12 @@ void LyXText::paintRowDepthBar(DrawRowParams & p)
|
||||
|
||||
int LyXText::getLengthMarkerHeight(BufferView * bv, VSpace const & vsp) const
|
||||
{
|
||||
if (vsp.kind() == VSpace::NONE)
|
||||
return 0;
|
||||
|
||||
int const arrow_size = 4;
|
||||
int const space_size = int(vsp.inPixels(bv));
|
||||
|
||||
if (vsp.kind() != VSpace::LENGTH) {
|
||||
return space_size;
|
||||
}
|
||||
|
||||
LyXFont font;
|
||||
font.decSize();
|
||||
int const min_size = max(3 * arrow_size,
|
||||
@ -3258,6 +3257,9 @@ int LyXText::getLengthMarkerHeight(BufferView * bv, VSpace const & vsp) const
|
||||
int LyXText::drawLengthMarker(DrawRowParams & p, string const & prefix,
|
||||
VSpace const & vsp, int start)
|
||||
{
|
||||
if (vsp.kind() == VSpace::NONE)
|
||||
return 0;
|
||||
|
||||
int const arrow_size = 4;
|
||||
int const size = getLengthMarkerHeight(p.bv, vsp);
|
||||
int const end = start + size;
|
||||
@ -3268,10 +3270,11 @@ int LyXText::drawLengthMarker(DrawRowParams & p, string const & prefix,
|
||||
int ty1, ty2;
|
||||
// y-values for bottom arrow
|
||||
int by1, by2;
|
||||
|
||||
str = prefix + " (" + vsp.asLyXCommand() + ")";
|
||||
|
||||
switch (vsp.kind()) {
|
||||
case VSpace::LENGTH:
|
||||
{
|
||||
str = prefix + " (" + vsp.asLyXCommand() + ')';
|
||||
case VSpace::LENGTH: {
|
||||
// adding or removing space
|
||||
bool const added = !(vsp.length().len().value() < 0.0);
|
||||
ty1 = added ? (start + arrow_size) : start;
|
||||
@ -3280,14 +3283,10 @@ int LyXText::drawLengthMarker(DrawRowParams & p, string const & prefix,
|
||||
by2 = added ? end : (end - arrow_size);
|
||||
break;
|
||||
}
|
||||
case VSpace::VFILL:
|
||||
str = prefix + _(" (vertical fill)");
|
||||
default:
|
||||
ty1 = ty2 = start;
|
||||
by1 = by2 = end;
|
||||
break;
|
||||
default:
|
||||
// nothing to draw here
|
||||
return size;
|
||||
}
|
||||
|
||||
int const leftx = p.xo + leftMargin(p.bv, p.row);
|
||||
@ -3307,6 +3306,9 @@ int LyXText::drawLengthMarker(DrawRowParams & p, string const & prefix,
|
||||
start + ((end - start) / 2) + d,
|
||||
str, font);
|
||||
|
||||
if (vsp.kind() != VSpace::LENGTH && vsp.kind() != VSpace::VFILL )
|
||||
return size;
|
||||
|
||||
// top arrow
|
||||
p.pain->line(leftx, ty1, midx, ty2, LColor::added_space);
|
||||
p.pain->line(midx, ty2, rightx, ty1, LColor::added_space);
|
||||
|
@ -22,6 +22,9 @@ What's new
|
||||
|
||||
** Updates
|
||||
|
||||
- when there is vertical space between paragraphs, the amount of space
|
||||
is also indicated in the small/medium/large case [bug #814]
|
||||
|
||||
** Bug fixes
|
||||
|
||||
- fix bug where opening the tabular dialog would mark the document as
|
||||
|
Loading…
Reference in New Issue
Block a user