diff options
| author | Nathan Lee <2431820-nathanal@users.noreply.gitlab.com> | 2019-05-03 09:48:32 +0000 |
|---|---|---|
| committer | Nathan Lee <2431820-nathanal@users.noreply.gitlab.com> | 2019-05-03 09:48:32 +0000 |
| commit | f09728fd9ddf319d8563eb198924ce922ee2e607 (patch) | |
| tree | 2399281bde623afb9b6e629ecbe02464b7e5d241 /src | |
| parent | Add double-conversion runtime library to snap (diff) | |
| download | inkscape-f09728fd9ddf319d8563eb198924ce922ee2e607.tar.gz inkscape-f09728fd9ddf319d8563eb198924ce922ee2e607.zip | |
Refer to correct array index in chunkAnchorPoint
Doesn't seem to make a difference in the "usual"
use case, but at least for Put on Path with the
Objects Dialog open, there is a difference.
Fix https://gitlab.com/inkscape/inbox/issues/421
Diffstat (limited to 'src')
| -rw-r--r-- | src/libnrtype/Layout-TNG-OutIter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libnrtype/Layout-TNG-OutIter.cpp b/src/libnrtype/Layout-TNG-OutIter.cpp index 1c20ac30b..ca52018af 100644 --- a/src/libnrtype/Layout-TNG-OutIter.cpp +++ b/src/libnrtype/Layout-TNG-OutIter.cpp @@ -292,13 +292,13 @@ Geom::Point Layout::chunkAnchorPoint(iterator const &it) const Alignment alignment = _paragraphs[_lines[_chunks[chunk_index].in_line].in_paragraph].alignment; if (alignment == LEFT || alignment == FULL) - return Geom::Point(_chunks[chunk_index].left_x, _lines[chunk_index].baseline_y); + return Geom::Point(_chunks[chunk_index].left_x, _lines[_chunks[chunk_index].in_line].baseline_y); double chunk_width = _getChunkWidth(chunk_index); if (alignment == RIGHT) - return Geom::Point(_chunks[chunk_index].left_x + chunk_width, _lines[chunk_index].baseline_y); + return Geom::Point(_chunks[chunk_index].left_x + chunk_width, _lines[_chunks[chunk_index].in_line].baseline_y); //centre - return Geom::Point(_chunks[chunk_index].left_x + chunk_width * 0.5, _lines[chunk_index].baseline_y); + return Geom::Point(_chunks[chunk_index].left_x + chunk_width * 0.5, _lines[_chunks[chunk_index].in_line].baseline_y); } Geom::Rect Layout::characterBoundingBox(iterator const &it, double *rotation) const |
