summaryrefslogtreecommitdiffstats
path: root/src/widget/wdisplay.cpp
AgeCommit message (Collapse)Author
2020-12-07Merge branch '2.3' of github.com:mixxxdj/mixxx into cleanup-headersJan Holthuis
2020-12-07Slimdown moc_compilation.cppDaniel Poelzleithner
The moc_compilation file became unbearable large, easily taking 10 minutes to compile whenever a Q_OBJECT changes. AUTOMOC scans for <basename>_moc.cpp includes and does not add the file to the moc_compilation whenever it is included in the propper cpp file. After this patch, moc_compilation.cpp is empty and the mocs are compiled with the approptial cpp, increasing recompile speeds by a factor of 10 when just a header file changed.
2020-12-02Merge branch '2.3' of github.com:mixxxdj/mixxx into cleanup-headersJan Holthuis
2020-11-19Pass non-trivial/large function args by referenceJan Holthuis
Fixes a bunch of `-Wclazy-function-args-by-ref` warnings. See https://github.com/KDE/clazy/blob/master/docs/checks/README-function-args-by-ref.md for details. Most of these changes are automated, using the clazy fixit by setting the `CLAZY_EXPORT_FIXES` before compilation and then running: $ mkdir /tmp/patch $ find ../src -iname "*.yaml" -exec mv {} /tmp/patch \; $ clang-apply-replacements /tmp/patch
2020-11-10Remove long copyright headersxerus2000
2018-03-24replace getSkinPath by makeSkinPath uisng skin: search pathDaniel Schürmann
2017-03-05use scaleFactor when loading imagesDaniel Schürmann
2016-05-09Improve extraction of state from QDomNodes in widget classes.RJ Ryan
Many widgets and common widget parsing code in LegacySkinParser used an inefficient method of accessing state: if (context.hasNode(node, "Foo")) { QDomElement foo = context.selectElement(node, "Foo"); } This is inefficient because of the double lookup (which is O(n) in XML children). This code is at the core of parsing the entire widget tree so the inefficiencies add up -- we run code of this pattern many hundreds of times for one skin.
2016-05-07Switch a lot of function arguments to const references in LegacySkinParser.RJ Ryan
2016-04-25Spring cleaning: Apply clang-tidy to src/widget.RJ Ryan
Using LLVM 3.8.0: $ clang-tidy --fix --checks="*,-llvm-header-guard,-readability-implicit-bool-cast,-readability-else-after-return,-google-readability-todo" $(git ls src/widget | xargs) -- (flags to compile)
2014-12-09Add scalemode support to most widget images.RJ Ryan
* Remove WStatusLight SizeMode as DrawMode is more general and covers its use cases. * Only call QWidget::setFixedSize if the DrawMode is FIXED. * Use FIXED as default DrawMode for most widgets for backwards compatibility. * Switch most Paintable::draw() calls to rectangle targets instead of (x,y) points. This allows the DrawMode to do the right behavior based on the mode.
2014-11-18Code fascism.RJ Ryan
* Fix compiler warnings in non-3rd-party code. * Add some missing const-references. * Eliminate cases of "if(" "( ... )" and "for(".
2014-10-01removing filename support for paintables + simplifying PixmapSourceJean Claveau
2014-09-30PixmapSource passed by valueJean Claveau
2014-09-09spreading getPixmapSourceJean Claveau
2014-07-08support for wdisplayJean Claveau
2014-04-05Eliminate unnecessary widget renders from control changes.RJ Ryan
Instead of re-rendering on every control change (via WWidget::onConnectedControlChanged), check for changes in what we would render first. Updated: WDisplay, WKnob, WKnobComposed, WSliderComposed, WStatusLight Left unchanged: WWaveformViewer, WPushButton, WOverview, WVuMeter
2014-02-17Change backpath attribute name from mode to scalemodeOwen Williams
Add attribute to status lights to optionally not setfixedsize
2014-02-16Refactor much of the backpath draw mode logicOwen Williams
2014-02-16implement mode="" attribute for all widgets that support BackPathOwen Williams
2014-02-16Implement selectable tile or stretch rendering.Owen Williams
Implement tiling SVG by pre-rendering
2014-01-12Remove WBaseWidget disabled state. Instead, use QWidget enabled property.RJ Ryan
As discussed in Bug #1180872, we should allow skin writers to connect controls to the enabled state of a widget to enable/disable widgets. This disables input events for widgets that are disabled or whose parents are disabled. * Remove old OnOff connection type. I haven't seen a single use of it since I joined the project in 2008. * Convert PropertyBinder into a ControlWidgetConnection. * Update WDisplay to check the QWidget enabled property. Currently only WDisplay supports rendering itself in a disabled state. I'll add support to more widgets in the future.
2014-01-10Rename methods for getting and setting connected control parameters to be ↵RJ Ryan
more clear.
2014-01-10Remove widget values.RJ Ryan
* WWidget no longer stores a value independent of its connected controls. * Make a connection explicitly the display value. For legacy reasons this is the last connection with connectValueToWidget. * Update all WWidget descendents to use the connected display value when painting. * Push buttons update the left or right connected control for push-button behavior or toggling. This allows WPushButton to toggle a multi-state button on left and right click. This was previously impossible.
2014-01-10Move disabled state into WBaseWidget. Rename to controlDisabled to prevent ↵RJ Ryan
clashing with QWidget.
2014-01-08Remove direct access to WWidget::m_value from child classes.RJ Ryan
2014-01-08Make WWidget::m_bOff private.RJ Ryan
2014-01-08Get rid of WWidget::getPath/setSkinPath in favor of using SkinContext for ↵RJ Ryan
skin path resolution.
2014-01-05Merge pull request #143 from rryan/potmeter_fixRJ Ryan
Normalize potmeter widget values to [0.0, 1.0] instead of [0.0, 127.0].
2014-01-04Fix WKnob / WDisplay active pixmap calculation to bias towards the lower of ↵RJ Ryan
the two middle pixmaps when there are an even number.
2014-01-03Revert "Revert "Normalize potmeter widget values to [0.0, 1.0] instead of ↵RJ Ryan
[0.0, 127.0]."" This reverts commit 6fcd283cd80a34747320340ecc9a17b9b4b9606a.
2014-01-03Revert "Normalize potmeter widget values to [0.0, 1.0] instead of [0.0, 127.0]."RJ Ryan
This reverts commit 328d5958483ceb33cee74def6c947111182b5af0.
2014-01-03Normalize potmeter widget values to [0.0, 1.0] instead of [0.0, 127.0].RJ Ryan
This is another step towards getting rid of MIDI assumptions that are baked into the widget system. * Control parameter space for potmeters is now [0.0, 1.0] instead of [0.0, 127.0]. * Non-linearity of parameter space (64 being the center value) now only applies to MIDI, not widgets. * Fix all potmeter-style widgets to use [0.0, 1.0] for parameter values.
2014-01-01Add SkinContext, a class for tracking and evaluating skin nodes within a ↵RJ Ryan
context. * Remove WWidget::select* methods. * Update all WWidget-style setup() methods to take a constant. * Migrate all non-skin uses of WWidget::select* to use XmlParse::select*.
2013-12-30Fix SVG rendering to scale with higher fidelity.RJ Ryan
* Use QSvgRenderer to scale SVG files instead of converting to QPixmap and scaling the pixmap. * Introduces Paintable class that wraps pixmaps and SVG images.
2013-12-29Allow WStatusLight, WDisplay and WKnob to be styled with a style sheet.RJ Ryan
2013-12-24Get rid of manual reference counting in WPixmapStore and just use ↵RJ Ryan
QSharedPointer.
2013-12-24Make WKnob inherit from WDisplay.RJ Ryan
WKnob shared a bunch of common logic with WDisplay since it's basically a WDisplay with input. WDisplay now has support for backgrounds and "disabled" widget support.
2013-12-24Refactor WDisplay to use a QVector of pixmaps.RJ Ryan
2013-12-08WPushButton can be connected to a dedicated indicator CO, + SomeDaniel Schürmann
refectoring for code style.
2013-06-19Moving mixxx/* to the root. A new era begins!RJ Ryan