Reputation: 6289
I noticed that DateChooser has the method setFirstDayOfWeek(int)
, but since DateChooser does not extend FormItem, I cannot use it in my DynamicForm instead of DateItem.
So, my question is, how do I make the calendar component in the popup to show Monday as the first day of the week?
Upvotes: 1
Views: 814
Reputation: 388
I'm not familiar with Smart GWT, but assuming the DateChooser item is based on native GWT date widgets, you can change its behavior by setting the locale of your application. Adding the following two lines to my [Application name].gwt.xml file (just below the "inherits" lines) changed these widgets to display Sunday-Saturday. I believe the default locale is "en" which was using a Monday-Sunday week (though it seems the opposite may be the case for you).
<extend-property name="locale" values="en_US"/>
<set-property name="locale" value="en_US"/>
Upvotes: 1
Reputation: 2071
When you want to use a widget which is not a subclass of FormItem
as in your case the DateChooser
you can use a CanvasItem
which can be added to your dynamicForm and add the DateChooser
as a member of this CanvasItem
.
Upvotes: 2