From wiki.ginstr.com
Jump to: navigation, search
(XML Attributes Description)
(XML Attributes Description)
Line 36: Line 36:
 
* <code>plusX</code> - Sets maximum date as current date plus <code>X</code> days
 
* <code>plusX</code> - Sets maximum date as current date plus <code>X</code> days
 
|-
 
|-
| title="Attribute" | <code>gn:textColor</code>
+
| title="Attribute" | <code>gn:textColor</code>(M103.8.1)
 
| title="Description" | Defines widget's color
 
| title="Description" | Defines widget's color
 
Can be
 
Can be

Revision as of 00:56, 25 March 2020

GnDatePicker

Widget XML tag
<com.ginstr.widgets.GnDatePicker>
Description
GnDatePicker inherits regular Android DatePicker widget.
It provides date entry.

XML Attributes Description

Attribute Description
gn:dataType Represents widget data type

Can be

gn:s_minDate Sets minimum permitted date

Can be

  • current - Sets the current date as minimum date
  • minusX - Sets minimum date as current date minus X days
  • plusX - Sets minimum date as current date plus X days
gn:s_maxDate Sets maximum permitted date

Can be

  • current - Sets the current date as maximum date
  • minusX - Sets maximum date as current date minus X days
  • plusX - Sets maximum date as current date plus X days
gn:textColor(M103.8.1) Defines widget's color

Can be

  • hardcoded - hexadecimal color representation e.g. #000000

Events

gn:act_setClick
gn:act_setLongClick
gn:act_setOnDate

Data types

Input
text
date
dateTime
Output
date
dateTime

Example

<com.ginstr.widgets.GnDatePicker
  android:id="@+id/meter_deinstallationDate" 
  android:layout_width="match_parent" 
  android:layout_height="wrap_content"
  gn:dataType="date" />