* feature More parameter item types
Pen: Pops up a dialouge that allows the user to customize a pen. Setting pen value is not working yet.
Progress bar: For indication things.
Slider: Easier way to set values that dont require precision.
Fonts: Picking font types. Next thing could be a Font dialog.
Calendar: For picking dates or intervals
Open/save file/files/directory: Pops up an open/save file/directory dialog to select a file/directory. Filter string and caption can be defined too.
A PenSelectorDialog widget was created for the pen parameter item too.
Also added these parameter items to the example.
* PyQt/Side6 compatibility fixup
* Revisions from intial PR
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialog.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/parametertree/parameterTypes.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/parametertree/parameterTypes.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialog.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Update pyqtgraph/widgets/PenSelectorDialogbox.py
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
Apply suggestions from code review
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
* Bugfix: module instead of class import on param tree example
* Enrich the slider parameter
* Address pijyoi comments on pen style parameter
* Different file picker for easier porting
* Better organization and formatting, minor refactoring
* PyQt6/PySide6 fixup for file dialog
* Minor adjustment to file picker
* Bugfix: for 'None' sigChanged
'None' is explicitly allowed for a WidgetParameterItem's `sigChanged` value. However, this raises an error on a changed value unless the commit's fix is applied
* Calendar works better as sub item
* Fixes bugs in pen parameter's dialog + makes it resizable
* more bugfixes and recommended changes, lets pen serialize its options
* better pen save state
* Fixes file parameter qualms
* Fixes font parameter qualms
* Fixes calendar parameter qualms
* Fixes multiply-defined slider optsChanged
* Fixes pen parameter qualms
* ptree example minor bugfix
* Pen dialog bugfixes
* File dialog bugfixes / mild improvements
* unto ptree save state regression
* file fixup
* Adds parameter descriptions to docstrings
* Improved parameter documentation
* adds 'relativeTo' option for file parameter
* Less abuse of Qt enums during or-operations
* More uniform handling of relative paths
* More cleanup of enum setting
* better name for window title (matches qt name)
* Favor os.path over pathlib
* Exposes 'directory', 'windowTitle' to file parameter
* Fixup and add comparison to parameter tree state restoration
* Exposes "cosmetic" in pen parameter
* Indicate defaults in parameter documentation
* QtEnumParameter works for enums outside QtCore.Qt
* see if altering pytest report fixes ci bug
* Cleanup unused import and redundant `self.widget` assignments
Co-authored-by: Fekete Imre <feketeimre87@gmail.com>
Co-authored-by: ChristophRose <42769515+ChristophRose@users.noreply.github.com>
* Remove the use of pyqtgraph.ptime
With us supporting python3.7+, we have no more need for the ptime module
and can instead safely use perf_counter for everything.
* Address small issues PR turned up
* Reword comment in ImageView
* Added clipItem option to LinearRegionItem
* Added a clipItem option to LinearRegionItem
Handle case when no self.viewBox() is yet available
* Implement LinearRegionItem clipItem
* Undo unnecessary change
* Update clipItem doc
* Fixup docstring formatting
* Cleanup
* Support clearing clipItem via setBounds. Fix initialization bug
* Add tests for LinearRegionItem clipItem
* Better clipItem demo in crosshair example
* Another test to verify claim in docstring
Co-authored-by: Arjun Chennu <arjun.chennu@gmail.com>
Co-authored-by: Ogi Moore <ognyan.moore@gmail.com>
Co-authored-by: Arjun Chennu <achennu@mpi-bremen.de>
* Allows filtering of examples
* For some reason, the ui designer ignored the courier font family so I manually inserted it into the .ui file
* Allows filtering by file content, too
* Respects dark mode (maybe?), fixes policy setting on code layout
* Prevents "run edited code" from showing unless the actual content changes
* Looks like black font is always best against highlight background
* Left test code in commit...
* Fix broken highlighting on PyQt6
* Address #133
* Better highlighting for both dark and light mode
* Minor refactoring/cleanup, uses combo box instead of checkbox
* Combo box below text edit to avoid clipping
Co-authored-by: njessurun <ntjessu@gmail.com>
* add axis convenient methods and matrix display example
* wrestled wayward space back into docstring
* color map names are case sensitive on Linux
* docstring fix for PlotItem
* protect AxisItem.linkToView from being obscured by DateAxisItem override
* replaced setOrigin method by promoted setPos and setScale
* made tri-state axes switching explicit
* reverted setRect behavior, documentation pass for ImageItem
* minor text adjustment
* implmented some suggested revisions
* fix input parsing for setRect and add tests so that I don't break it again
* don't try to re-add transform after clearing it
* changed example and doc image generators to pg.exec()
* removed commented-out code
* cleaned up transform eqaulity assertion
* restored devoured comment
* restored devoured comment
The way we called subprocess.Popen, it looks like we didn't close all
the pipes; this PR addresses the warning that pytest generates when
running the examples.
In addition, we toggle the pytest setting to error on any warning
Remove if __name__ == "__main__" bits, replace some == None to is None
checks
Cleanup variety of static code checker issue
Removed missing imports, restructured some logic to make a little
cleaner, fixed a function in test_dockarea, unfortunately broke the test
so now I tell pytest to expect the Exception.
* added convenience functions to better handle plotting with gradients
* docstring correction, example name correction
* retrying to get documentation format right
* another attempt at cleaning up docs
* Don't hardcode timer type (and docs fixing attempt)
* more docstring re-formatting
* linebreaks in docstrings
* more documentation adjustments
* documentation pass
* some corrections to documentation
* more adjustments to documentation
* again?
* removed some whitespace and redundant blank lines, changed some checks '== None' to 'is None'
* fixed mis-spelling QColor as Qcolor
* Improve HistogramLUTItem docs, a few cosmetic changes
* Initial implementation of horizontally-oriented HistogramLUTItem
- Also adds support in HistogramLUTWidget
- Fixes AxisItem orientation bug for vertical orientation
- Make use of GradientEditorItem orientation (fixes another bug for
vertical orientation)
- Use horizontal orientation in an example for demonstration
* Remove unused HistogramLUTItem option
* A few more minor fixups
* Copy paste bug
* Use f-strings
* Update from review and a couple more minor updates
* Woops
* Add doc for orientation arg
* Add top/bottom orientation to doc. Expand on levelMode doc a bit
This change makes use of QPointF methods which perform faster than the python
equivalent methods. Furthermore, some tests are added.
* Set __slots__ to empty tuple for pg.Point
* Make Point.angle() behave as Vector.angle()
Static code checker identified multiple places where a file is opened
but is not necessarily closed. This commit addressed that with the
exception of RemoteGraphicsView.py
Significant performance issues have been identified with np.clip
and thus clip_array was created to speed up the operation. In addition
clip_scalar was created to clip a scalar value between two other values
this commit replaces many uses of np.clip from operating on scalars to
using clip_scalar instead
Using numpy methods that are intended for vectorized operations is
substantially slower than using the math module, so when feasible the
math module methods should be used.
* NEW features for HistgramLUTItem
* gradientPosition=('left', 'right')
* only paint if item is visible (is faster)
* link hisogram to other histograms
* fixes to be able to merge
* drop linkHistogram (rgba needs to be better integrated)
* make sure defaults to same as current behavior
* draw connecting lines correctly on each side
* add example use
When running on macOS Big Sur, pyopenGL is unable to find the bindings
Previously this was assumed that it would be fixed in later versions
of Python 3.8, but that has not happened.