GnImageEditor
- Widget XML tag
<com.ginstr.widgets.GnButton>
- Description
- Widget is used for image editing. Images are stored into widget as layers. Each image is equal to one layer. Once desired image is created it can be retrieved and stored.
XML Attributes Description
Attribute | Description |
---|---|
gn:centeredLockedImage
|
Image which will be loaded as centered and locked image. Image is loaded on top of other layers once data is set to this widget i.e. another image
Can be:
|
gn:canvasBackgroundColor
|
Represents a background color which is set as background (last layer) in GnImageEditor
Can be
|
gn:editMode (M104)
|
Represents a mode where drawing tools can be used for drawing
Can be
|
Events
gn:act_resetWidgets
- default state is blank canvas painted withgn:canvasBackgroundColor
and all "layers" removed
Example
<com.ginstr.widgets.GnImageEditor android:id="@+id/imageEditor" android:layout_width="match_parent" android:layout_height="0dp" android:layout_weight="1" android:layout_marginTop="10dp" android:layout_marginBottom="10dp" android:layout_marginLeft="10dp" android:layout_marginRight="10dp" gn:canvasBackgroundColor="#00FFFFFF" gn:dataType="pictures" gn:centeredLockedImage="@drawable/settings"/>