Commit Graph

20 Commits

Author SHA1 Message Date
Lucie Gérard
a7956df3ca Use SPDX license identifiers
Replace the current license disclaimer in files by
a SPDX-License-Identifier.

Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-08-26 12:27:18 +00:00
Knud Dollereder
aea64ca1fa Add zoom slider to the curve editors toolbar
Removed the "Set Default" button from the toolbar since
it does the same as the "linear interpolation" button
and space is rare in the toolbar.

Fixes: QDS-6951
Change-Id: Ifdbf20af2e5365e9bf9b592783b872394cabb7eb
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Aleksei German <aleksei.german@qt.io>
2022-08-22 14:31:08 +00:00
Knud Dollereder
1df1a065de QmlDesigner: Improve usability of boolean animation curves
Boolean animation curves are now painted from min to max of the value range
instead of from 0 to 1. This allows to see value changes when the curve is
loaded together with other animation curves of different value ranges.

Boolean curves are now forced to be step interpolated.
If the user tries other interpolation types the request is denied and an
error message is written in the new status line.

Added a status line that displays the current frame number by default and
an informative text in case the user did something forbidden.

Respect the current state when populating the curve editor.

Fixes: QDS-6950
Fixes: QDS-6889
Change-Id: Ia5fa1c1c55ee93eda5a39fd83987b54fb41d54db
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-07-08 13:20:26 +00:00
Knud Dollereder
9195d0dd2c Improve Animationcurve editor
- Prevent insertion of invalid animation ranges that may cause DS
  hanging
- Properly update the toolbar when switching to a different qml file
- Show an informative text instead of the empty curve editor when
  the current file does not contain a timeline
- Move the toolbar into its own class
- Add an implentation to the "Set Default" button

Fixes: QDS-6543
Fixes: QDS-6542
Fixes: QDS-6545
Fixes: QDS-6544
Change-Id: Id6bc1457627ea23a670e74ea335fbb475711b9a6
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-04-28 10:01:46 +00:00
Alessandro Portale
d7ed48ac6f Add missing "emit"s
Change-Id: I88a7397c7689b1e72cdd0e52077f8097443963c0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-11-11 14:10:42 +00:00
Knud Dollereder
6d32550459 Improve 2d view navigation
- Get rid of lag when two-finger-swiping
- Enable one finger swipe and scroll gestures for the magic mouse
- Fixed a bug where the toolbar zoom slider from the transition.-
and timeline editor where not updated when zooming with a gesture.
- When scrolling the curve editor, its toolbar was scrolling together
with the rest of the view. This is now fixed in order to be
consistent with the timeline view and transition editor.

Change-Id: I611015af134976588fbcada0bc5ccfdcf8039c27
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-10-29 11:35:40 +00:00
Thomas Hartmann
a07112258b QmlDesigner: Disable Timeview and CurveEditorView when widget is invisble
Task-number: QDS-5159
Change-Id: Ibae0b9742d4aaac6a1def1c84342a031baf75256
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-10-01 14:03:45 +00:00
Knud Dollereder
1ba7c149af Enable step functions in the curve-editor
... and shut-up an annoying qDebug log in the transition-editor.

Change-Id: Iea8b48e48bb7e52cd4c845f28c49f8a513785fab
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-03-04 14:48:19 +00:00
Christian Kandeler
521745856f Fix warnings about unused lambda captures
This is the subset of clang complaints that MSVC does not disagree with.

Change-Id: I0bc38b0c847d1c54f1ac9cca95d93577d39ddfcd
Reviewed-by: hjk <hjk@qt.io>
2020-12-14 10:00:16 +00:00
Knud Dollereder
8ca3b557da Update locking state from external views and cleanup
Improve treeview styling related to locking/pinning
    Use font icons.
    Show implicitly locked nodes by darkening text and icon.
    Show implicitly locked curves by darkening the text.
    Show unlocked/unpined icons only when hovering the mouse above the item.
It is now possible to lock/pin multiple curves by locking/pinning the node items.
Load unselected curves into the graphicsview when pinning them.
Rename namespace DesignTools to QmlDesigner.
Remove unused function from the timeline module.
Get rid of a memory leak.

Change-Id: I2c9c0a9e1ffe79520c4869178a11cc5825d04bbe
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-10-28 13:13:56 +00:00
Knud Dollereder
3bce5f2e76 Convert the CurveEditorDialog to a view-plugin
Continuously send frame-changed signals when dragging the playhead
Fix timescale painting
Paint playhead behind the valuescale

Task-number: QDS-2551
Change-Id: Ia8d3952b4401500a4c6d31ff9f5742ff44b2c092
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-11 13:28:09 +00:00
Knud Dollereder
20e95f2f19 Add the ability to unify keyframe handles
Task-number: QDS-568
Change-Id: I5b102423e8e166d41edf199c42305cee102e8b54
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-03-25 16:11:28 +00:00
Knud Dollereder
6cc080e055 Make sure to neither load nor store invalid qeasing-curves
Remove set-value-spinbox.
Do not convert single-segment-qeasing-curves to bezier if they would become invalid.
Do not store invalid qeasing-curves in the keyframe ModelNode.
Make sure that a conversion does not produce nans

Change-Id: I0688de55bf6b0ef6fe69d70d9192d852c8d6b895
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-03-19 12:30:22 +00:00
Knud Dollereder
5b000d17cb QmlDesigner: Add the ability to modify the animation range
Add the ability to modify the animation range from the curve editor

Fix a synchronization issue between timeline and curve editor when
the animation contains pinned curves

Change-Id: I89dda234063259f41d662749d696f5fc8a04f988
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-03-17 17:19:14 +00:00
Knud Dollereder
841f5be97e Implement locking and pinning of animation-curves
Fixes: QDS-550
Fixes: QDS-551
Change-Id: I53a120a3753bb98fe729106b7e996f475fbda2f1
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-02-11 12:13:00 +00:00
Knud Dollereder
16bd822d1b Move selection related code into SelectionModel
And fix a bug where the curves where missing in the graphicsview after opening the
AnimationCurveDialog a second time.

Change-Id: I4f13bd345afafaa0578a3be28be6326fa232dbe1
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-12-03 10:10:22 +00:00
Knud Dollereder
a4bff368fd Display the current frame in a dedicated control
Enable immediate dragging of the playhead after clicking into the time-scale
Rename "Curve Picker" to "Easing Curve Editor" and "Curve Editor" to
"Animation Curve Editor"

Change-Id: I0085a26d0ea510286586d89c6cddb9bbe720e49e
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-10-31 11:08:58 +00:00
Thomas Hartmann
b6070995e0 QmlDesigner: Add icons to curve editor
Change-Id: I77f9b28f8cfe04022571d9c0cc092b9206c4df60
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2019-08-13 14:01:43 +00:00
Knud Dollereder
4a673896a6 Connect CurveEditor edits to the timeline module
Change-Id: Ic00e0840da34bdbb8627b2fe2d8546a867b24966
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-08-08 14:30:44 +00:00
Knud Dollereder
376c6b9d59 Add curve editor
Moved qmldesignerextension into component

Updated build systems

Change-Id: I8d2d0757a1639a472d426b66c0c8ae6fb84cc3d2
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-06-19 09:22:31 +00:00