| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
The test I wrote was not testing if calling undo/redo had any effect
on emitting undoCommandAdded(), added these test cases and fixed the
QTextDocumentPrivate::endEditBlock so we now again emit only when an
undo command is added, not also on calling undo or redo.
Reviewed-by: mae
Reviewed-by: Samuel Rødal
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QTextFormatCollection currently has two problems:
- looking for the index of a QTextFormat is linear, this can take 25%
cpu when loading large documents in kword
- the hash function for QTextFormat is inadequate. Not all values are
treated specially. E.g. each QBrush instance has the same hash value
at the moment.
These patches speed up loading of a large text document in KWord from 9
to 7 seconds.
This fixes this by using QMultiHash to group the QTextFormat instances
by hash and only loop through that list when looking up values. It also
improves the hash function for QTextFormat.
Merge-request: 1623
Reviewed-by: Olivier Goffart <ogoffart@trolltech.com>
|
| |\ |
|
| | |\
| | | |
| | | |
| | | |
| | | | |
Conflicts:
src/gui/painting/qbrush.cpp
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The font comparison (operator==) didn't check the capital attribute, which is
the one responsible for this variant. Now it does. Auto-test updated.
Reviewed-by: Samuel
Reviewed-by: Olivier
|
|\ \ \ \
| |/ / /
| | | |
| | | |
| | | | |
Conflicts:
dist/changes-4.6.0
|
| |/ /
| | |
| | |
| | |
| | |
| | | |
The word 'module' was missing.
Reviewed-By: TrustMe
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Workaround: fntstore.h has an inlined function
'COpenFont* CBitmapFont::OpenFont()' that returns a private data member.
The header will change between minor SDK versions, thus break BC. But
Qt has to build on any SDK version and run on other versions of Symbian
OS. Also Qt does not want to deliver that BC to Qt based apps.
This hack performs the needed pointer arithmetic to get the right
COpenFont* pointer, no matter if the 'Flexible Memory Model' is already
supported or not.
The author is not proud of this commit.
Task-number: QT-2250
Reviewed-by: Iain
Reviewed-by: Shane Kearns
modified: src/gui/text/qfontdatabase_s60.cpp
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
QPaintDevice and QImage used the functions numColors(), setNumColors(),
and numBytes(). However, this is not consistent with the rest of the Qt
API which uses *Count() and set*Count().
Removed all usage of these functions inside Qt and test-cases.
Reviewed-by: Andreas Aardal Hanssen
|
| |\ \ |
|
| | |\ \
| | | |/
| | | |
| | | |
| | | | |
Conflicts:
dist/changes-4.6.0
|
| | |\ \ |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This fixes the issue in the itemviews that the selection would not
change when clicking on rich text labels.
Task-number: QTBUG-4516
Reviewed-by: ogoffart
|
| | |\ \ \ |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
We cannot simplify spaces because a font may have several spaces in
its name.
If we only add spaces when needed when merging tokens, we don't need
to simplyfy the string later
The CSS tokenizer will already make sure that spaces are removed if
there is no quotes (btw, the CSS specification says that there must
be quotes if there is spaces, but we tollerate if there is no quotes)
Reviewed-by: Jocelyn Turcotte
Task-number: QTBUG-4344
Task-number: 258586
|
| |\ \ \ \ \
| | | |_|/ /
| | |/| | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
There is an optimization in QTextControl, that it only requests
updates for single blocks if only a single block was changed. This
update was requested with the block's bounding rectangle.
In the case of disabled line wrapping in combination with a very long
line, a block change can result in a narrower block bounding rectangle.
This then resulted in pixel on the screen not being redrawn properly.
The fix enlarges the requested update rectangle horizontally.
The bug was discovered during inhouse Qt Creator testing.
Reviewed-by: Oswald Buddenhagen
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
QFxTextEdit, as well as systems with keypad navigation, needs the text
control to ignore navigation events that have no effect (like hitting
the right navigation key at the end of the text.) Previously, we would
only support this for keypad navigation. This patch introduces a flag
that you can set to tell the QTextControl to ignore these events. If
the flag is not explicitly set, behavior should remain as before.
The if-test has been refactored to make it more readable.
Done-with: Alan Alpert
Reviewed-by: Samuel
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
We need to copy the abstract text layout's custom object handlers as
well when we temporarily use a different QTextDocument.
Task-number: QTBUG-5397
Reviewed-by: Simon Hausmann
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
QPen does not have a constructor which only takes a single QBrush.
Reviewed-by: Gunnar
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Reviewed-by: Simon Hausmann
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Reviewed-by: Eskil
|
| |_|_|_|/
|/| | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Also removed a redundant setBrush(), as it will be followed by
painter->restore() a few lines below.
Reviewed-by: Eskil
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Missing comma in qfontdatabase.cpp
Reviewed-by: Gunnar
|
| |/ / /
|/| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Enables N'Ko support in Qt, after having now a harfbuzz version
that supports it.
Task-number: QTBUG-1042
Reviewed-by: Gunnar
|
|\ \ \ \
| |_|_|/
|/| | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Previously we didn't update the editor contents if the new preedit
string was empty. However, it could be empty because the user just
erased it, so the bug was fixed by checking whether the preedit
string in the event and in the editor are different.
RevBy: Denis Dzyubenko
|
|\ \ \ \
| |/ / / |
|
| |/ /
| | |
| | |
| | |
| | |
| | |
| | | |
fontDef.pixelSize is a qreal now and we should round it after
multiplication to avoid an accuracy loss.
Reviewed-by: mae
|
| |\ \ |
|
| | |\ \
| | | |/ |
|
| | | |\
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
src/gui/effects/qgraphicseffect.cpp
|
| | | | |\ |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This amend previous commit by removing the duplicate function.
The quote need to be escaped in attributes.
Reviewed-by: Thomas Zander
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
If a QTextDocument contains an anchor with a & in it, this & is not
escaped in the toHtml() function, meaning the resulting document
can't be parsed as XML as it will contain invalid entities.
Reviewed-by: Olivier Goffart
Merge-request: 1753
|
| | | | |\ \
| | | | | |/
| | | | |/|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
git://gitorious.org/~fleury/qt/fleury-openbossa-clone into openbossa-fleury-fixes3
Conflicts:
src/gui/graphicsview/qgraphicsanchorlayout_p.cpp
src/gui/graphicsview/qgraphicsanchorlayout_p.h
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Fixes a refcount bug that occurs when QFont is constructed from a
QFontPrivate* that was created without an initial ref().
Merge-request: 1831
Reviewed-by: Olivier Goffart <ogoffart@trolltech.com>
|
| | | |_|/
| | |/| |
| | | | |
| | | | |
| | | | |
| | | | | |
However, compiling with QT_NO_ICON will still not work :(
Reviewed-by: tom
|
| |\ \ \ \
| | | |/ /
| | |/| | |
|
| | |/ /
| |/| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Formerly, QTextDocument::revision() could be used to guesstimate the
number of available undo steps that was used in Qt Creator to store
cursor positions in parallel to the actual text contents. Now that
revision() is strictly increasing, another means is needed, therefore
the new functions providing the needed data.
Reviewed-by: mae
|
| |/ /
|/| |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When the stringToCMap() fails, it can be because it did not have enough
space in the layout, or it can because of other errors. In order to
implement "try-again" processing in a simple way, we had an infinite
loop which assumed that stringToCMap() would always succeed in the
second run (which would be the case if the only possible error was
"not enough space".)
Since there are other possible failures not related to the number of
glyphs, you could easily get into an infinite loop here, e.g. when
laying out text that contains the Byte Order Mark.
The fix changes the implementation to explictly try stringToCMap()
twice at max, and is also how it's implemented in the default
qtextengine.cpp.
Task-number: QTBUG-4680
Reviewed-by: Trond
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
On Mac OS X, Cocoa, we would synthesize italics on the text by slanting
it in the incorrect direction (so it leaned to the left) when generating
a path from the text, e.g. when printing.
The patch makes the text slant the correct way, and the logic now
becomes identical with the synthesized italics in the draw() function.
Task-number: QTBUG-4969
Reviewed-by: Trond
|
|/ /
| |
| |
| |
| |
| |
| |
| | |
Font names were not retrieved correctly after the QT_WA removal patch.
The old code always used the GetTextOutlineA() API, except for WinCE,
even when a Unicode compatible Windows platform was used.
Reviewed-by: Kim
|
| |
| |
| |
| | |
Reviewed-by: Sarah Smith
|
| |
| |
| |
| |
| |
| |
| |
| | |
After 04d18b38c38c5ff623b30366ea08d56128b9b7d0 Qt didn't compile for
QWS. Will email original committer to verify that original intent is
maintained.
Reviewed-by: Donald Carr <donald.carr@nokia.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QTextEdit (via QTextLayout) and QPlainTextEdit in Qt used to ignore
any font leading but added one extra pixel in QFontMetrics. With many
freetype fonts, this resulted in a "spacy" text layout.
The necessary fixes on X11 and Windows were to take (positive) leading
into account, to make the font database convert point sizes to pixel
sizes without rounding to plain integer values, and to subtract the
extra pixel from QFontMetrics from the font engines' descent value.
The change also fixes several places in styles and widgets, where
QFontMetrics::lineSpacing() was wrongly used instead of
QFontMetrics::height().
Ideally we should also handle negative leading, which would require
additional and bigger code changes in QTextLayout and QPlainTextEdit.
In addition, all other editors we have tested seem to ignore leading on
X11. If we choose to believe the values provided by freetype, our text
layout would be one pixel smaller than everybody else's.
On the Mac, this change does nothing. There our layout is still too spacy,
and for smaller fonts quite ugly compared to native Mac applications.
Done with mae.
Reviewed-by: mae
|
|\ \
| |/ |
|
| |
| |
| |
| | |
Reviewed-by: thartman
|