History log of /haiku/src/apps/icon-o-matic/gui/TransformerListView.cpp
Revision Date Author Comments
# 4b0dffe5 21-Aug-2023 Zardshard <0azrune6@zard.anonaddy.com>

Icon-O-Matic: Make list items copy/pastable

Also:
* make transformers draggable
* clean up archiving code

Partially addresses #18400

Change-Id: Ibc384a1919e1330113a5e2857da16284181a834e
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6869
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# c6c2c042 08-Aug-2023 Zardshard <0azrune6@zard.anonaddy.com>

Icon-O-Matic: Add perspective transformations

As part of adding perspective transformations, agg_trans_perspective.h
was patched to fix a multiple definitions error. This change has been
submitted for review to the "upstream" repositories at [1], [2],
and [3].

Also includes various other improvements such as VertexSource being
split into its own file, code style improvements, and documentation
improvements.

[1] https://sourceforge.net/p/agg/patches/6/
[2] https://github.com/ghaerr/agg-2.6/pull/9
[3] https://github.com/aggeom/agg-2.6/pull/7

Change-Id: I4bffd2f87354bde10155e23145a232a925be6ff3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6801
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# a4e4beaf 18-Jul-2023 Humdinger <humdingerb@gmail.com>

IOM: Localization/String improvements

* Switching mis-used B_TRANSLATE_CONTEXT to B_TRANSLATE_COMMENT
* Use B_TRANSLATE_SYSTEM_NAME for "Icon-O-Matic"
* Remove remnants of old localization system
* Rename "Control Points" to vertex/vertices
* Add a ":" after Undo/Redo
* Sentence casing
* Avoid Yes/No buttons in BAlert

Change-Id: Ibb299925bce1f6ca1cf03216a36df7c44f10bdc6
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6704
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 64279352 22-Jun-2023 Zardshard <0azrune6@zard.anonaddy.com>

Icon-O-Matic: Generalize some classes

* Turns PathContainer, ShapeContainer, StyleContainer into Container.
* Makes Shape use Container for storing Tansformers instead of
reinventing the wheel yet again.
* Moves common logic from AddPathsCommand, AddStylesCommand,
AddShapesCommand, and AddTransformersCommand to AddCommand.
* Factors out common logic from two more commands similar to above.
This adds the MoveCommand and RemoveCommand classes.
* Cleans up some code style.

Change-Id: I59eca94a1c45eac608514f269f6e5f8628f93fab
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6640
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# 098eaec6 08-Jun-2023 Zardshard <0azrune6@zard.anonaddy.com>

Icon-O-Matic: Add reference images

Fixes #2748

Also fixes a comment misstating a function's name and code style.

Change-Id: I609a1f1e100ded647818e70b428cedc48cf29036
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6604
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# 14f0e6d7 09-Jun-2015 Janus <janus2@ymail.com>

Icon-o-Matic: list views use system colors

* Fixes #10840.
* Properties view needs more work for dark themes
(There is another ticket for that).


# 0cbb6c11 09-May-2015 Stephan Aßmus <superstippi@gmx.de>

Icon-O-Matic: Make GradientTransformable a BReferenceable

* Switch to using support/Referenceable.h instead of using an older copy
of this code.
* Make GradientTransformable a BReferenceable and fix #12033.


# 546208a5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

More catalog-related cleanup.

* rename B_TRANSLATE_CONTEXT to B_TRANSLATION_CONTEXT and
B_TRANSLATE_WITH_CONTEXT to B_TRANSLATE_CONTEXT, squashing a TODO
* adjust all uses of both macros in Haiku's source tree
* use correct header guard for collecting/Catalog.h

The renamed macros require adjustments to all external applications
using catalogs.


# 518852fc 29-Dec-2010 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Dziadek: localize IconOMatic


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40025 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7974d3dc 13-Jan-2010 Stephan Aßmus <superstippi@gmx.de>

Patch by Humdinger:
Updated Haiku apps to use sentence-case. What a huge undertaking...
The files where I had to apply the patch manually (for mysterious
reasons) have also gotten a whitespace cleanup. I've proof-read
everything so hopefully there should be no problems.

This should be the final part of #5169.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35049 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5c0e62f0 27-Jul-2009 Stephan Aßmus <superstippi@gmx.de>

Disabled the Transformation and Perspective transformers for the time being.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31807 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 464cd15f 21-Nov-2006 Stephan Aßmus <superstippi@gmx.de>

* you can now assign styles to shapes that had none assigned before
* Transformer menu is correctly enabled/disabled when a shape is selected


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19351 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 84153c7a 21-Nov-2006 Stephan Aßmus <superstippi@gmx.de>

* various UI improvements and fixes


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19347 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0e1ba39f 29-Aug-2006 Stephan Aßmus <superstippi@gmx.de>

* merged Icon-O-Matic from Ingos layout branch into trunk (r18134:18685)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18686 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 61b0e9e3 12-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* added a little bit of tracing to object destruction, since there
seems to be a problem when quitting the app
* added Undo/Redo commands for numerous operations
- (un)assigning VectorPaths to Shapes
- adding new VectorPaths
- removing VectorPaths
- adding Shapes
- transforming Shapes
- adding Styles
- changing Style color
* there was a mix up in classes inheriting from SimpleListView,
RemoveItemList() gives a list of item pointers, not indices
* GradientControl sent the focus notification to the window instead
of the set BHandler target
* StyleView takes care of transfering the current Style color or
the focused gradient stop color to the CurrentColor object, so
the current color of the SwatchGroup is synced
* small improvement to layout of SwatchGroup
* SwatchGroup no longer knows anything about a Style
* fixed syncing the global Selection to the listview selection
at least for ShapeListView
* implemented cloning Shapes
- added Transformer::Clone(VectorSource& source) to all Transformers
- ShapeListView uses this when dropping shapes with shift pressed
* updated NOTES
* added Transformable::matrix_size, so that "6" isn't hardcoded
everywhere (though it still is at most places)
* added listener interface to TransformBox, this is used by
the new TransformObjectsCommand, as long as the TransformBox still
exists, the command modifies the TransformBox transformation instead
of messing with the objects itself
* fixed hotspot size in TransformBox by using the zoom level of
the CanvasView
* TransformBox rotates/scales correctly around the visible pivot
* fixed TransformCommand toggling to transformation (the diff was bogus)
* Gradient doesn't trigger unnecessary notifications in SetColor()
* CanvasView doesn't eat keyboard events when the GradientControl or
one of the ListViews has focus (is a hack currently...)
* fixed bug in PropertyListView when it calls the PropertyChanged()
hook: because of the notification mechanism, the Properties might
be toast after the hook returns
* moved all GetProperty() implementations from headers into .cpp files



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18122 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4215c452 08-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* implemented MoveTransformersCommand (so Transformers can be
drag sorted now)
* implemented RemoveTransformersCommand
* implemented StyleListView (I promise, this is the last list view :-)
* implemented adding new styles via the Style menu
* implemented selecting the Style of the currently selected Shape


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18072 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e2a31283 05-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

many improvements and bug fixes:
* added VertexSource::SetLast() used by PathSource
to call agg::path_storage::close_polygon(). The
StrokeTransformer avoids this of course. Affine
and PerspectiveTransformer forward this to their source.
* TransformerItems watch their transformers for notifications
* made VectorPath an IconObject
* VectorPath no longer uses close_polygon() when converting
to agg::path_storage to allow open strokes
* added IconObjectListView which inherits from
PropertyListView and allows to edit the properties of the
last selected object from one of the other list views
* fixed a couple bugs when adopting properties:
- removed the Property* in the PropertyEditorView base
class, and made GetProperty() virtual, as the base class
pointer was not maintained and superfluous
- delete the old PropertyObject in PropertyListView::SetTo
when adopting the properties instead of the object whose
properties were adopted...
* added SetPropertiesCommand to allow Undo/Redo on changes
of properties
* Style is also an IconObject now (TODO: yet another list view
for styles... :-)
* Style watches its Gradient for notifications and builds and
caches the color array now
* removed generating the color array for each scanline in
IconRenderer, so the performance is improved a lot
* Shape watches its Transformers for notifications in order
to trigger rerendering
* StrokeTransformers adds a bunch of properties like stroke
width, cap and join mode
* StateView keyboard filter no longer steals keydown events
from BTextViews
* PropertyItemViews resize with the parent
* refined the interface for PropertyListView for easier
tracking of the changed properties in derived classes
* added HasPendingNotifications() to Observable, so that
IconObjects can track changes more easily when adopting
a PropertyObject
* the name is now part of any IconObject


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18045 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bab183a2 04-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* Transformers have Name() now
* added TransformerFactory to instantiate the various types via the GUI
* added Transformer menu to main window
* added TransformerListView that shows the Transformers applied to the
selected Shape
* implemented more powerful listener interface for Shape, used by
TransformerListView


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18027 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 14f0e6d73d4ee697753149a03ebb0dff13bc0cc5 09-Jun-2015 Janus <janus2@ymail.com>

Icon-o-Matic: list views use system colors

* Fixes #10840.
* Properties view needs more work for dark themes
(There is another ticket for that).


# 0cbb6c11eec74201f566920c90ebd2c5546b7aa6 09-May-2015 Stephan Aßmus <superstippi@gmx.de>

Icon-O-Matic: Make GradientTransformable a BReferenceable

* Switch to using support/Referenceable.h instead of using an older copy
of this code.
* Make GradientTransformable a BReferenceable and fix #12033.


# 546208a53940a26c6379c48a7854ade1a8250fc5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

More catalog-related cleanup.

* rename B_TRANSLATE_CONTEXT to B_TRANSLATION_CONTEXT and
B_TRANSLATE_WITH_CONTEXT to B_TRANSLATE_CONTEXT, squashing a TODO
* adjust all uses of both macros in Haiku's source tree
* use correct header guard for collecting/Catalog.h

The renamed macros require adjustments to all external applications
using catalogs.


# 518852fca73d16198413de528219fcdfa6b04647 29-Dec-2010 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Dziadek: localize IconOMatic


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40025 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7974d3dcf39ce78e5885b481eee12e561ad6e096 13-Jan-2010 Stephan Aßmus <superstippi@gmx.de>

Patch by Humdinger:
Updated Haiku apps to use sentence-case. What a huge undertaking...
The files where I had to apply the patch manually (for mysterious
reasons) have also gotten a whitespace cleanup. I've proof-read
everything so hopefully there should be no problems.

This should be the final part of #5169.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35049 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5c0e62f05afee580bfeb48d26f8904f8fa5cf801 27-Jul-2009 Stephan Aßmus <superstippi@gmx.de>

Disabled the Transformation and Perspective transformers for the time being.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31807 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 464cd15f0af4fb072d9b50e9d3e2a077f4d3d4db 21-Nov-2006 Stephan Aßmus <superstippi@gmx.de>

* you can now assign styles to shapes that had none assigned before
* Transformer menu is correctly enabled/disabled when a shape is selected


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19351 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 84153c7a0c3a6df07e996ca265884ec5308a1c2a 21-Nov-2006 Stephan Aßmus <superstippi@gmx.de>

* various UI improvements and fixes


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19347 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0e1ba39f0440e200e30b6a648e70c3e8683dc5f7 29-Aug-2006 Stephan Aßmus <superstippi@gmx.de>

* merged Icon-O-Matic from Ingos layout branch into trunk (r18134:18685)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18686 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 61b0e9e3149012ccbd48a10dcbc7f83600bb4769 12-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* added a little bit of tracing to object destruction, since there
seems to be a problem when quitting the app
* added Undo/Redo commands for numerous operations
- (un)assigning VectorPaths to Shapes
- adding new VectorPaths
- removing VectorPaths
- adding Shapes
- transforming Shapes
- adding Styles
- changing Style color
* there was a mix up in classes inheriting from SimpleListView,
RemoveItemList() gives a list of item pointers, not indices
* GradientControl sent the focus notification to the window instead
of the set BHandler target
* StyleView takes care of transfering the current Style color or
the focused gradient stop color to the CurrentColor object, so
the current color of the SwatchGroup is synced
* small improvement to layout of SwatchGroup
* SwatchGroup no longer knows anything about a Style
* fixed syncing the global Selection to the listview selection
at least for ShapeListView
* implemented cloning Shapes
- added Transformer::Clone(VectorSource& source) to all Transformers
- ShapeListView uses this when dropping shapes with shift pressed
* updated NOTES
* added Transformable::matrix_size, so that "6" isn't hardcoded
everywhere (though it still is at most places)
* added listener interface to TransformBox, this is used by
the new TransformObjectsCommand, as long as the TransformBox still
exists, the command modifies the TransformBox transformation instead
of messing with the objects itself
* fixed hotspot size in TransformBox by using the zoom level of
the CanvasView
* TransformBox rotates/scales correctly around the visible pivot
* fixed TransformCommand toggling to transformation (the diff was bogus)
* Gradient doesn't trigger unnecessary notifications in SetColor()
* CanvasView doesn't eat keyboard events when the GradientControl or
one of the ListViews has focus (is a hack currently...)
* fixed bug in PropertyListView when it calls the PropertyChanged()
hook: because of the notification mechanism, the Properties might
be toast after the hook returns
* moved all GetProperty() implementations from headers into .cpp files



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18122 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4215c452a4a92759e04b8c221016fea48531f1bc 08-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* implemented MoveTransformersCommand (so Transformers can be
drag sorted now)
* implemented RemoveTransformersCommand
* implemented StyleListView (I promise, this is the last list view :-)
* implemented adding new styles via the Style menu
* implemented selecting the Style of the currently selected Shape


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18072 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e2a31283dde5ae5dfc14c3d2075e0d17cf392892 05-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

many improvements and bug fixes:
* added VertexSource::SetLast() used by PathSource
to call agg::path_storage::close_polygon(). The
StrokeTransformer avoids this of course. Affine
and PerspectiveTransformer forward this to their source.
* TransformerItems watch their transformers for notifications
* made VectorPath an IconObject
* VectorPath no longer uses close_polygon() when converting
to agg::path_storage to allow open strokes
* added IconObjectListView which inherits from
PropertyListView and allows to edit the properties of the
last selected object from one of the other list views
* fixed a couple bugs when adopting properties:
- removed the Property* in the PropertyEditorView base
class, and made GetProperty() virtual, as the base class
pointer was not maintained and superfluous
- delete the old PropertyObject in PropertyListView::SetTo
when adopting the properties instead of the object whose
properties were adopted...
* added SetPropertiesCommand to allow Undo/Redo on changes
of properties
* Style is also an IconObject now (TODO: yet another list view
for styles... :-)
* Style watches its Gradient for notifications and builds and
caches the color array now
* removed generating the color array for each scanline in
IconRenderer, so the performance is improved a lot
* Shape watches its Transformers for notifications in order
to trigger rerendering
* StrokeTransformers adds a bunch of properties like stroke
width, cap and join mode
* StateView keyboard filter no longer steals keydown events
from BTextViews
* PropertyItemViews resize with the parent
* refined the interface for PropertyListView for easier
tracking of the changed properties in derived classes
* added HasPendingNotifications() to Observable, so that
IconObjects can track changes more easily when adopting
a PropertyObject
* the name is now part of any IconObject


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18045 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bab183a27305174861a27a136599b863d22318c7 04-Jul-2006 Stephan Aßmus <superstippi@gmx.de>

* Transformers have Name() now
* added TransformerFactory to instantiate the various types via the GUI
* added Transformer menu to main window
* added TransformerListView that shows the Transformers applied to the
selected Shape
* implemented more powerful listener interface for Shape, used by
TransformerListView


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18027 a95241bf-73f2-0310-859d-f6bbb57e9c96