| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a fonts property to the style that allows you to set fonts per
control, similarily to what we do in QQuickTheme.
The fonts are propagated from the style to the theme, and from the
fallback style to the style. That means that if a font is not set
for a theme or style, it will be resolved against its fallback font.
Since both the QQStyleKitTheme and QQStyleKitStyle should have a
fonts property, introduce a common base class: QQStyleKitThemeProperties
that contains the fonts property. Later, the palettes can be moved
there as well.
Also add a font property to the QQStyleKitReader that is suposed to
return the font for the current control being read.
Change-Id: I116c1ab9bc426570756476ee409513587c475a0d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
Implement Utils::shiftHighlights to apply diffs to cached highlights.
Fallback to shifted highlights when DOM is invalid to avoid recompute.
Refactor handlers to use shifted tokens and update result IDs and cache.
Add unit tests and invalid fixtures covering deletions and partial edits.
Task-number: QTBUG-140645
Change-Id: Ic230af0e3d995e85959beee3dfa37a987843c119
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Now that qmlls uses the same import paths as qmllint, we warn multiple
times if the import paths are bad, once in the qmlls.build.ini
generation code and once in the linting target creation part. Add a
target property to avoid warning multiple times.
Change-Id: If427e17dbf4e21cb0121bf2acced9dccb228e221
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a test to avoid QTBUG-142025 from regressing, and log a message with
qInfo() when receiving EOF to simplify debugging qmlls in the future.
This should help to tell if qmlls stopped on start because of
QTBUG-142025 or other reasons (invalid signature, or the qmlls client
trying to spawn qmlls from a filepath that does not exist for example).
The actual fix of QTBUG-142025 is in qtbase and tracked via QTBUG-142041.
Fixes: QTBUG-142025
Pick-to: 6.10
Change-Id: I9cd215ac02e23a1d833755eda058d72622de7318
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
| |
Change-Id: Ic2bb88c34938dda87864094595de8b7553d9508e
Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
|
| |
|
|
|
|
|
|
|
|
| |
You can call splice with only one argument, after all.
Pick-to: 6.10 6.8 6.5
Fixes: QTBUG-142253
Change-Id: I3dec244325fd4d57a045ec024968e26e4f6372db
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
It uses FolderListModel.
Pick-to: 6.10
Task-number: QTBUG-137440
Change-Id: I44cc4f312dddde756bbb33aa7a564c1c4085c75e
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
| |
Lottietoqml and the corresponding VectorImage backend are no longer
in tech preview in Qt 6.11.
Change-Id: I73647ff0d1df263b314b0535d988823b44afa34b
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
|
| |
|
|
|
| |
Change-Id: I3dbd469b26914b0380bb781c1c2993a43657bd4e
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
|
|
|
|
| |
Pick-to: 6.10 6.8 6.5
Change-Id: I1bd30625e474ea4e36c6fb252afbbe2cd9e17162
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
dvValueLazyField is not really expressive, rename it to show that it
calls the visitor argument on a field-wrapped version of its lazy
field argument.
Task-number: QTBUG-142187
Change-Id: I96b065a55257e62d5d6b970a5487c33b389a0b04
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
dvReferenceField is not really expressive, rename it to show that it
calls the visitor argument on a reference-wrapped version of its
reference argument.
Task-number: QTBUG-142187
Change-Id: I2ceb90b63e3e63bb4acd9f5d19278eddf1a51a3a
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
| |
dvWrapField is not really expressive, rename it to show that it calls the
visitor argument on a field-wrapped version of its field argument.
Task-number: QTBUG-142187
Change-Id: Ied467d5fa857934dea069982672f313cd961eb67
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
| |
dvValue is not really expressive, rename it to show that it calls the
visitor argument on a value-wrapped version of its value argument.
Task-number: QTBUG-142187
Change-Id: I95e37f72e8596185294ecf92452b6925eb17e606
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
| |
It only calls its first argument with the two other arguments, and does
not use this. Remove it and replace all usages with a direct call.
Task-number: QTBUG-142187
Change-Id: Icb42f38199803ee5c1fac1636d10430e7385551b
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
It only calls wrap(). Replace all usages, and change the first
argument to use PathEls::Field(). This helps unclutter the DomItem
interface.
Task-number: QTBUG-142187
Change-Id: I3aeda82b95948dde7bb7b07ab573585ac11958a6
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
It only calls dvItem(). Replace all usages, and change the second
argument to use PathEls::Field(). This helps unclutter the DomItem
interface.
Task-number: QTBUG-142187
Change-Id: Ieb14e4cf1d542ba257ec3d23b290504148cbf5ed
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
It only calls dvValue(). Replace all usages, and change the second
argument to use PathEls::Field(). This helps unclutter the DomItem
interface.
Task-number: QTBUG-142187
Change-Id: If32856e115528c1c0f8db737e8c7c78d3912c233
Reviewed-by: Semih Yavuz <semih.yavuz@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There are cases, such as Item2D in QtQuick3D, where a Qt Quick user
interface is not placed directly inside a QWindow. In that case,
Menu and other Popup items need to be shown in the context of the
toplevel Item rather than the window.
There are two separate Popup implementations: A popup can either be
a toplevel window known to the windowing system, or it can be an Item
that lives in a special Overlay layer, which normally fills the entire
window.
This change adds private C++ API in QQuickItemPrivate to add a custom
Overlay to an Item. This does not in any way affect the case where a
popup has its own toplevel window.
Task-number: QTBUG-142145
Change-Id: Ic96a450f6d47e43d1ffc8226b27c1dc5d62e3497
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need strong references for the cases where we place guards on the
stack to prevent the deletion of the objects, and weak references we
hand out to the view. The views don't systematically track the objects
they hold and generally use a QPointer as second line of defence. In
certain cases we cannot avoid deleting objects that are in fact still
referenced as the clearObjectWeakReferences() call shows. If the
QQmlDelegateModel itself is deleted while some view still holds a weak
reference to an object, we cannot avoid deleting that object, no matter
if the view agrees.
Also, we can do with 16bit numbers for the references. The guards on the
stack are rather few and you'll overflow the stack before you hit the
16bit maximum. The references handed out to the views are generally one
or two per item.
Task-number: QTBUG-141963
Change-Id: Ifb79e993abcaf4c169b08641ebc2a6378e0a4776
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
They need to link the styles they import so that the dependencies are
clarified (and also they'll in fact need the linkage if we ever compile
them in direct mode).
Pick-to: 6.10
Task-number: QTBUG-137440
Change-Id: I6edaba4390dce4f9cc2b95586f28331192cc01ff
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
macOS 26 (Tahoe) changed NSSearchFieldCell: the magnifying glass icon is
taller. Drawing it at the button's full rect causes the top to be clipped
by the bezel, though the clear icon remains fine. To avoid this, we
render the search icon at a fixed, smaller size to prevent upscaling
and eliminate clipping after 26.0.
Fixes: QTBUG-141776
Pick-to: 6.10
Change-Id: Ifb5f4476253e55e700b8b89e864afdbb2ceedd8f
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch will add support for Instance Variations. Instance
Variations allows you to define one or more style variations in
a StyleKit style that can be activated from the application
using an attached 'StyleKitControl.variations' object.
Instance Variations will affects all descendant StyleKitReaders
of the item that contains the attached object.
For example, if you set "StyleKitControl.variations: ['mini']"
on a GroupBox, all controls inside that GroupBox will
be affected with the variation named "mini" in the style
(if any).
Inside a variation, you specify which controls should
receive alternative styling when the variation is applied.
Any properties defined in a Variation override those
set in the Style or Theme.
In order to support Instance Variations, this patch will also
refactor how we implement Type Variations, which are variations
that applies to _all_ controls of a specific type, rather
than to individual instances.
Change-Id: I6486979281997e69b65da0ed4866b264c91c592f
Reviewed-by: Doris Verria <doris.verria@qt.io>
|
| |
|
|
|
| |
Change-Id: Ic9eeeb5658f9f6251191406a68649705b6389b55
Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
|
| |
|
|
|
|
|
|
|
| |
This will match them with Q4A.
Task-number: QTBUG-138877
Pick-to: 6.10
Change-Id: Ia5cb1954b361f7f0abb788c326045f71da202607
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
|
| |
|
|
|
|
|
| |
Don't take unnecessary temporaries and move values into place.
Change-Id: I2b871c365e068a8665c03497f72b91106001a0cd
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Add const references to the loops to avoid copies.
Change-Id: I08cfc615d5a40e88a41de23750a0416b6309b1dc
Coverity-Id: 897432
Coverity-Id: 897433
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch introduces 'virtual' and 'override' keywords.
From the grammar perspective they are qml contextual keywords,
first of all to preserve backwards compatibility
(do not break the users code if they had object attributes named
"virtual" or "override")
"final" is made qml contextual keyword for the sake of consistency
(to treat all "virt specifiers" equally)
Change-Id: Ice13a77c8b54ce8219cd45cc7085fb3f10a5e908
Task-number: QTBUG-98320
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
This patch will add a new example to Controls that demonstrates the
new StyleKit API that has recently been added to Qt.labs. It
contains a few styles that the user can choose between, where each
style has a different level of complexity.
Change-Id: Ie193105c05759eee2b4f4deb9d1932448d7e36c5
Reviewed-by: Doris Verria <doris.verria@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch introduces a new styling API for Controls called
StyleKit. StyleKit provides a higher-level, key–value–based
approach to styling applications, serving as an alternative
to working directly with the lower-level Templates API.
The primary goal of StyleKit is to offer a unified API for
styling both Controls and Widgets. The current Templates-based
approach relies heavily on JavaScript, which makes it unsuitable
for use with Widgets. This initial version supports Controls
only; support for Widgets will be added in a future update.
StyleKit is designed to make it easier for designers and UI
developers to:
- Focus on visual styling rather than Template logic (such as
geometry, delegate positioning, and handle placement).
- Allow style properties to propagate, enabling you to factor
out common styling into shared control types and override only
what differs in the more specific control types.
- Style controls independently in each of their states, without
needing nested ternary expressions to check state.
- Define and apply multiple themes with minimal effort.
- Provide different style variations depending on context.
For example, styling a Switch differently when it appears
inside a ToolBar.
[ChangeLog][Qt labs] Introduced new QML module 'StyleKit'.
StyleKit provides a flexible styling framework for Qt Quick
Controls, enabling developers to define reusable styles and
themes using a simple key-value property format.
Change-Id: Iae25324486aea7a7b9b2ce52135327ec7e9b6f59
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch removes an optimization where we std::move the changed
register into its target. A copy is performed instead. This resolves
the more urgent issue of miscompilations.
QTBUG-141920 has popped up and was either exposed or introduced by
b303e0624d2ea2ab1c124961e7510a64d0ca1412.
That change performs optimizations that avoid intermediary copies of
values between registers. It was found that, in the process, the mapping
from RegisterContent to variable name stored in m_resiterVariables was
changed. One RegisterContent no longer uniquely maps to a variable name
because of the direct moving of values to their destination. The
registers alias the same value. This could cause issues and might need
to be addressed.
The original std::move was only added after 6.5 by
3193911b02424dd0365e03526a4c12ed7888b7ca. Cherry-pick to the later
versions.
Fixes: QTBUG-141920
Pick-to: 6.10 6.8
Change-Id: Ie6dad1a809ac5ee08de70971ec92d3c97fc50080
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
| |
I've caught it timing out on these.
Change-Id: I0fd7d575823fab857d4e24d5841e8d6708f00a93
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
We cannot encode the "running" state of a profiling adapter into the
features it's recording. It may be started with no actual features
enabled and then we still need to stop it eventually.
In order for the QmlProfiler test to work without the DebugMessages
feature we still need to create the DebugMessages client, but ignore its
output. Otherwise the logic that checks "unrelated" clients gets
confused.
Change-Id: I52a3c2bc55ea36454ab9c8c7f25fe833c7f14a43
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
| |
I've caught it timing out by just a few ms several times.
Change-Id: I0f9d80421a5845dc0582fd028c7c3d33d9f6bc54
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
|
|
|
|
|
|
| |
Since there are two kinds of references, we need to be more specific.
Task-number: QTBUG-141963
Change-Id: I8583b91fab62abec49a5f71652e8c04fa8906b7b
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Script references to QQmlDelegateModelItems were references held by
either the created delegate object, the incubation task, or the heap
object that holds the QQmlDelegateModelItem. However, for the object and
the incubation task we only incremented the script reference counter if
they were not populated by QQmlTableInstanceModel. Indeed it makes very
little sense to hold a script reference for those in general. The
incubation task is explicitly checked on isReferenced() and for the
object we have a separate reference count.
Encapsulate the reference counting and drop the unnecessary references.
Check the object in addition to isReferenced() where it matters.
Task-number: QTBUG-141963
Change-Id: Id0fcb7d36afcfc131f52584fc9bcab8989ff7fc1
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
| |
The fact that we can't determine a target window is inconsequential as
long as we don't have any events to replay.
Change-Id: Id61cff371ac31d0a2dee37b7c33244adda03756e
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
3 or 4 hex digit color names are fine, too:
#abc is equivalent to #aabbcc
and
#abcd is equivalent to #aabbccdd
Pick-to: 6.10
Change-Id: I2c6ed5926b921cb1a357bdaefbe456f845990b21
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Found by GCC -Wnrvo, which we intend to add to headersclean.
To fix, factor the tail part of the function into a private
helper. This preserves git history on the complete original code,
compared to the "usual" solution of wrapping the tail part of such
functions in an IILE.
Amends fa259ed4ff84a5952cdb6d2c6215e92d65afa56a.
Note: The amended commit manually cherry-picked to 6.5, but only
partially, and QQmlListProperty::toList() was not part of the pick.
While this adds a new member function to a public class, this is
forwards BC, because the added entity is a member function template.
Member function templates are never part of the ABI, even if their
class was inherited by a wholesale-exported class.
Pick-to: 6.10 6.8
Task-number: QTBUG-142146
Change-Id: I3d559c6432b636608f94f29f03203111b6a95990
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
If the directory to be created or removed is at an absolute path, we can
just as well use the root path to carry out the operation. The result
will be as unrelated to the preview as any other mkdir/rmdir operation
elsewhere.
Task-number: QTBUG-141569
Change-Id: I156f230a7bbbd07215334649026319a977ff063e
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
|
| |
|
|
|
|
| |
Fixes: QTBUG-141747
Change-Id: Icc194fb35da84f580b3bdfcb64944f5834b766dc
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Add some information what the original attribute is (a signal, method or
property).
Task-number: QTBUG-141854
Change-Id: Ia4c6ea889b99658df2a6f5ee80e7b5628e398c8c
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Print the qml name of root file name components instead of its base
type when using getScopeName.
Task-number: QTBUG-141854
Change-Id: I53f830a03edeaf0a23251583d4fa20da9ee8f5d0
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Warn when shadowing properties/signals/methods in qmllint. Move the
already existing duplicate property check into its own static method
warnForDuplicates, and extend it to check whether base types also
have a property of the same name. Use it when analysing definitions
of methods, signals and properties in qmljsimportvisitor to warn about
shadowed properties.
As a drive-by change, fix the sourcelocation of the duplicated property
warning to point to the name of the property/signal/method instead of
the "property" or "function" keyword.
To avoid adding more testcases to the already big
tst_qmllint::dirtyQmlSnippets_data(), create a new
tst_qmllint::shadow_data() method for the shadow related tests, and
make tst_qmllint::shadow() call dirtyQmlSnippet(). This allows to reuse
the test code from dirtyQmlSnippet without making dirtyQmlSnippets_data
grow even more.
Adapt some existing test-cases by adding qmllint disable directives
where shadowing was wanted, and disable the shadow category on
tst_qqmljsscope (which does not make use of the qmllint code that reads
qmllint disable directives), as it seems that tst_qqmljsscope tests that
shadowing works as expected (shadowing is a feature, after all...).
I guess this patch might need to be updated in the future once we have
override and virtual properties in QML via QTBUG-98320.
Make the qmlShadow warning non-critical for qmltc, as qmltc supports
shadowing, to avoid breaking the qmltc tests.
Task-number: QTBUG-141854
Change-Id: I74c1b413e2c19a0db34215b34a9b65d43fbef6ce
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Add a method to grab the owner of a method of a qqmljsscope, in the same
way as ownerOfProperty() does. A later patch will use it to warn about
shadowed methods.
Task-number: QTBUG-141854
Change-Id: I21247151ee3d7d298329d0bdfb2f5e0e1dd51b33
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
| |
Task-number: QTBUG-140645
Change-Id: I72d3dbbe88f1902dc6f520cdefbc2577dea531ce
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement deletion handling for semantic highlight tokens so that
tokens remain consistent after text removals. Classify tokens
relative to the deleted range and apply one of:
- keep tokens before the deletion
- shift tokens after the deletion (adjust offset, line, column)
- trim or move overlapping tokens (left/right fragment or drop)
Add helpers for overlap detection, column/line adjustment, and
an updateHighlightsOnDelete routine. Call it from Utils::applyDiffs.
Add unit tests covering single-line and multi-line deletions.
Task-number: QTBUG-140645
Change-Id: I55c1c41dc1bb58435d001a8960089b8b605ab1e9
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add logic that shifts existing highlight tokens when the document is
modified and becomes invalid. Introduce the applyDiffs helper, which
takes a list of diffs between the current document and the last valid
one.
High-level strategy:
Represent highlights as a map from offset to HighlightToken. Maintain a
cursor into the old document that marks the current insertion point.
For Diff::Equal, advance the cursor by the length of the equal text and
leave all highlights unchanged.
For Diff::Insert, compute insertion metadata and classify each existing
token relative to the cursor.
Tokens before the insertion remain unchanged.
Tokens after the insertion are shifted forward by the inserted length.
If the insertion is on the same line, adjust startColumn. If it contains
newlines, update startLine and recompute startColumn.
Tokens overlapping the insertion are expanded. If the insertion is in
the middle of the token, extend the token until the first whitespace to
avoid merging separate words. If the insertion begins before the token
start, move the token start to the insertion point and adjust length and
line or column values.
After processing all diffs, build the shifted highlight set and swap it
in.
Task-number: QTBUG-140645
Change-Id: Ib0431c702100517e2658a48c8ae7f2ae141dbc8c
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
QtC has a well-tested diff calculator which works in the core of
DiffEditor plugin. Adapt it in qtdeclarative to be
used as qmlls utility by modernizing a little and removing the
unnecessary api that won't be needed. The first use case will be
shifting highlights based on the calculated differences. Also,
regexp-based highlighting would perform only on the diffed context
rather than the entire source code.
Task-number: QTBUG-140645
Change-Id: I5e88e4c6d77c1432b25eb226f9f5444928b9b156
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
| |
Change-Id: I9833c9c690b89e57ca511dd2a43e7a979c97367a
Reviewed-by: Andreas Eliasson <andreas.eliasson@qt.io>
|