| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Fix text color in some cases of QML and QStaticText
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts 518c2a58ed6fdfd7449cb4476aa8ea0d32ad16e3 which caused a
regression.
When writing systems are mixed and an underline is set on the font,
QPainter will set a pen with the current color and a new width on
itself before drawing the decoration. This would cause the recorder
in QStaticText to mark the pen as dirty, saving the current pen
color in all subsequent text items. The effect was e.g. that in QML
the cached color would override the current one, making it impossible
to change the color on the text without forcing a relayout somehow.
The right fix is to only mark the pen as dirty when its color actually
changes.
Task-number: QTBUG-20159
Reviewed-by: Jiang Jiang
|
|\ \
| |/ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This is a back-port of part of cad70d64d0bbada. In the raster engine's
drawCachedGlyphs(), which is used by QStaticText, we would use the wrong
metrics to lay out the glyphs, because loadGlyphMetrics() would assume
full hinting. A visible effect of this was that the baseline of rotated
text became wavy.
Task-number: QTBUG-18185
Reviewed-by: Jiang Jiang
|
| |
| |
| |
| |
| |
| |
| | |
Clicking at the edge of a glyph means lookup for the left glyph.
Reviewed-by: TrustMe
(cherry picked from commit 31110bf84bb06d57983501fa65fe0db3f7c61927)
|
| |
| |
| |
| | |
Reviewed-by: TrustMe
|
| |
| |
| |
| |
| | |
Task-number: QTBUG-19260
Reviewed-by: TrustMe
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We need to find out the closest element in the ligature to
the point we clicked (or tapped), currently we do this by
dividing the width of that ligature glyph evenly by the number
of characters it covered. We only support Common and Greek script
at this point, ligatures in other scripts are still handled as a
whole.
Task-number: QTBUG-19260
Reviewed-by: Eskil
|
| |
| |
| |
| | |
Reviewed-by: Eskil
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
For widgets like QPlainTextEdit, selection across ligatures (typically
'fi', 'ffi', 'fl', etc.) end up highlighting the entire ligature
glyphs, this patch fixed that by dividing width inside the ligature so
that selection will not expand past the actual selected characters.
Since cursor position already considered this, we merely adopted the
algorithm and made it a separated helper function for all necessary
cases. Dividing width directly looks like a temporary workaround but
works well enough so far for cursor positions.
Task-number: QTBUG-11969
Reviewed-by: Eskil
(cherry picked from commit 99fd5825dfb4d50cff93165995701a65b7a8e4ed)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit fcfc19878a0a1a48194a786bba64da11606077d2.
I am happy that this commit fixed three bugs at once. But
Actually, I am not sure if QTBUG-15513 should be fixed at
this point. Fact is that the patch as it is would have changed
the point->pixels calculation back to how it was in Qt 4.6.
This means that the fonts which are defined with pointSize
would now (in Qt 4.7.4) suddenly be bigger than they were
in Qt 4.7.3. Imho this is unacceptable, as it would break
all layouts which were developed for Qt 4.7 apps, when
point size (instead of pixle size) was used.
I will need to fix QTBUG-17844 without fixing QTBUG-13009
If QTBUG-13009 will be fixed for 4.8 will be discussed.
|
| |
| |
| |
| |
| |
| |
| |
| | |
As QTBUG-19880 highlighted, the old S60 naming is not suitable for
these classes anymore.
Task-number: QTBUG-19913
Reviewed-by: Jani Hautakangas
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Unlike QFont::pixelSize(), which may return -1 if the font size was
defined in points, QFontInfo::pixelSize() always needs to return a
valid value.
c4ef479906f073fa84999eb950f00e264ebd4e8e which was a fix for
QTBUG-13009 tried to fix a similar issue, but failed to do that
properly, which resulted in QTBUG-15513 and QTBUG-17844.
This commit is supposed to fix all three bugs.
Task-Number: QTBUG-13009
Task-Number: QTBUG-15513
Task-Number: QTBUG-17844
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In FreeType, there's a fall back to QFontEngine::alphaMapForGlyph()
when the fonts are very large. Since this uses a QPainterPath containing
an unhinted glyph, the use of hinted metrics would sometimes lead to
the glyphs being clipped because they would be positioned slightly
outside the image they were painted into. When outline drawing is on,
it makes sense to return unhinted metrics, since the glyphs we will
actually use are unhinted.
Task-number: QTBUG-19067
Reviewed-by: Jiang Jiang
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Updating file with CRLF line endings for the updated header
Fix a regression in QList::mid()
update gitignore
remove -fno-stack-protector
Fix make confclean
Update licenseheader text in source files
|
| |
| |
| |
| |
| |
| |
| | |
Updated version of LGPL and FDL licenseheaders.
Apply release phase licenseheaders for all source files.
Reviewed-by: Trust Me
|
|\ \
| | |
| | |
| | |
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Make TextEdit word selection more natural.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
QTextControl will only extend the selection to a word if the cursor is
directly over it which prevents the selection being extended if the
mouse is dragged up or down a to a shorter line of text making it
difficult to select multiple lines of text. Just disable that
limitation when the TextEdit word selection is enabled.
Change-Id: I3b9d1575c0141db8441197d740de94a90eacc077
Task-number: QTBUG-19230
Reviewed-by: Martin Jones
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Ensure the TextEdit cursor delegate is repositioned on mouse events.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Update the micro focus when a mouse press changes the cursor position
of a read only TextEdit.
Change-Id: I11855037f7938b2cd23ac6ad165722b5289b4f46
Task-number: QTBUG-19109
Reviewed-by: Martin Jones
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If glyph is not found from glyphSet it is created dynamically and
in this case not deleted.
Task-number: https://projects.maemo.org/bugzilla/show_bug.cgi?id=244326
Merge-request: 1208
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
|
| |_|/
|/| |
| | |
| | |
| | |
| | |
| | |
| | | |
Because it breaks forward compatibility. We will use the original
fix in 4.8. In 4.7 we just make sure it doesn't crash in
QTextBlock::next().
Reviewed-by: Thiago Macieira
|
|\ \ \
| |/ /
| | /
| |/
|/|
| | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Ignore changes to selectByMouse during a selection.
PathView offset out of sync with currentIndex when items are removed.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Use the value of selectByMouse at the time of a mouse press event in
all subsequent mouse events in a sequence. This is the same as
ignoring the intial mouse press except mouse events for other actions
are still accepted.
Change-Id: I59b50bf95d26c6320e6e74eeb679b4153e0edf4d
Task-number: QTBUG-18887
Reviewed-by: Martin Jones
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
So that it can take trailing space width into account when
doing right aligned text drawing.
Backported from master.
Task-number: QTBUG-18303
Reviewed-by: Eskil
|
|\ \
| |/
| |
| |
| | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix TextEdit cursorRectangle property.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Translate the cursor rectangle from control coordinates to painting
coordinates rather than the other way around, ensure the cursor
delegate is also translated, and update the cursor rectangle, cursor
delegate and micro focus when the preedit cursor changes position.
Change-Id: Iac7a87f7fb965d5f56d059d8f4b97feef8b47789
Task-number: QTBUG-18515 QT-4827
Reviewed-by: Martin Jones
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Make sure removed QTextBlock is invalid
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If the block is removed from document block map, we will mark the
right node to the current head->freelist index, but it shouldn't
be accessed directly, otherwise it can cause crash because of
uninitialized node.
Hence we need to check if a node index is equal to current freelist
index. If so, it cannot be a valid block.
Task-number: QTBUG-18500
Reviewed-by: Eskil
|
|\ \ \ |
|
| |\ \ \
| | |/ /
| |/| /
| | |/
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix text selection with shift-click.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Move the cursor when word selection is NOT enabled. If word selection
is enabled then then cursor would have been moved in a previous branch,
the (incorrectly inverted) check was to prevent that being overridden.
Change-Id: I788c3b41c6fdb250d6086893ea98a1aa8c302514
Task-number: QTBUG-18017
Reviewed-by: Alan Alpert
|
| |\ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Make sure num_glyphs pass to HarfBuzz is large enough
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
(Backport from master)
Currently we only pass the num_glyphs for the run to
HB_ShapeItem, but it can be less then the string length
for this run because of Unicode surrogates. Thus, we need
to pass at least the length of that run as num_glyphs to
HB (given that we have enough space allocated because for
the entire string), if that's still not enough, we will
do ensureSpace again according to the num_glyphs returned
by HB and move remaining glyphs backwards.
Task-number: QTBUG-15679
Reviewed-by: Lars Knoll
|
| |\ \ \
| | |/ /
| | | |
| | | |
| | | |
| | | |
| | | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Don't crash calling QTextDocument::blockBoundingRect on invalid block
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If the block is invalid, QTextBlock::layout() will return 0 and we would
dereference a null pointer.
Task-number: QTBUG-18192
Reviewed-by: Jiang Jiang
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When ATSFontGetName() did not set name to the font name then it would
cause Qt to fall back to a font that was not the right one. Therefore
calling ATSFontFamilyGetName() in this case will help ensure it gets the
right font.
Reviewed-by: Jiang
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Designer: Fix a bug affecting tab reordering of promoted tab widgets.
Designer: Fix a bug clearing the Z-Order when adding a new widget.
Adjust right bearing when breaking with line separators
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If we found a forced line break with line separator (e.g. '\n'),
take the right bearing of previous glyph into account, otherwise
the resulting text width will be slightly smaller than the one
without a line separator.
Task-number: QTBUG-17020
Reviewed-by: Eskil
|
|\ \ \
| | |/
| |/|
| | |
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix TextEdit mouseSelectionMode overriding selectByMouse.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If selectByMouse is false don't allow any text selection on mouse
move.
Change-Id: Ic9f309899bc0de48066a2393e088e15b3a2f06db
Task-number: QTBUG-18072
Reviewed-by: Martin Jones
|
|\ \ \
| | |/
| |/|
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Fix QGraphicsScene returning incorrect focus item.
Not requiring valid QTextBlock in previous()
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Commit 64852122ba7 introduced a regression in QTextBlock::previous(),
programs that do doc.end().previous() will not be able to retrieve
the last valid block. Revert this change so that we can keep the
behavior consistent with previous versions.
Task-number: QTBUG-18026
Reviewed-by: Eskil
|
|\ \ \
| | |/
| |/|
| | |
| | |
| | |
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix unstable qdeclarativeflickable test.
Update TextEdit's visible selection when only the anchor changes.
Set correct initial value for TextEdit and TextInput canPaste property
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
At the limits of a TextEdit's text a key press can change/reset the anchor
position without changing the cursor position. Checking the cursor position
alone isn't enough to determine the selection hasn't changed.
Change-Id: Ic425ac0c06897d77e9c86b907ff10b39d78dd7a1
Task-number: QTBUG-17982
Reviewed-by: Martin Jones
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix TextInput auto test failure on mac.
Fix word selection locking on string boundaries.
Fix potential crash in QTextControl.
QDeclarativePropertyMap::keys() cannot be called from qml
Compensate for horizontal scroll in TextInput micro focus.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
inputContext() is only safe to call if there is a current
contextWidget.
Change-Id: I6cbccf5f5fbb2d8c9ca6acf5f7e02f680eb84483
Reviewed-by: Andrew den Exter
|
|\ \ \
| |/ /
|/| /
| |/
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Fix Mac synthesized italic fonts clipping issue for QGLWidget
Fix cursor position adjustment when removing strings
Fix out of bounds handling in Mac shaper
|
| |
| |
| |
| |
| |
| |
| | |
Backport 43d5a0757d857c2a6694ae81d6b70c04ef876aff from 4.8.
Task-number: QTBUG-16954
Reviewed-by: Eskil
|