Bug 433870 - [DateTime calendar] option to start on Monday instead of Sunday
Summary: [DateTime calendar] option to start on Monday instead of Sunday
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.4   Edit
Hardware: PC Mac OS X
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2014-04-30 12:23 EDT by Steven Spungin CLA
Modified: 2021-09-08 02:48 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steven Spungin CLA 2014-04-30 12:23:30 EDT

    
Comment 1 Abhishek Kishore CLA 2014-05-14 01:13:07 EDT
You're suggesting this option be implemented on all platforms, and not just Mac, right?
Comment 2 Steven Spungin CLA 2014-05-14 07:16:12 EDT
For starters I'm suggesting it on all platforms that support if using a native widget that does, and all others that use an emulated as the source is obviously available in that case.
Comment 3 Lakshmi P Shanmugam CLA 2014-06-19 03:37:12 EDT
On Mac, currently this can be set in the System preferences. 

On Mac, this can implemented this using NSCalendar.setFirstWeekday(). But we need to evaluate if it possible on other platforms.
Comment 4 Arun Thondapu CLA 2014-06-19 04:47:39 EDT
(In reply to Lakshmi Shanmugam from comment #3)
> On Mac, currently this can be set in the System preferences. 
> 
> On Mac, this can implemented this using NSCalendar.setFirstWeekday(). But we
> need to evaluate if it possible on other platforms.

According to the GTK+ API reference [1], 

GTK_CALENDAR_WEEK_START_MONDAY - Since GTK+ 2.4, this option is deprecated and ignored by GTK+. The information on which day the calendar week starts is derived from the locale.

[1] https://developer.gnome.org/gtk2/stable/GtkCalendar.html#GtkCalendarDisplayOptions
Comment 5 Steven Spungin CLA 2014-06-19 19:35:40 EDT
If the native code does not support it, can't we just fallback to an emulated java calendar?  

Also, I don't think the Eclipse install should rely on the System settings if the developer wants to specify the start day.
Comment 6 Abhishek Kishore CLA 2014-06-20 00:38:51 EDT
> Also, I don't think the Eclipse install should rely on the System settings
> if the developer wants to specify the start day.
The start day of a calendar is a "generic" preference. Its unlikely that the user would want the start day to be Sunday in one application, and Monday in another. So it makes sense for it to be controlled at the OS(e.g.-locale) level, isn't it?
Comment 7 Steven Spungin CLA 2014-06-20 07:31:40 EDT
If the OS has a preference setting, then I would add third option for the DateTime to use the OS setting as well.  I do not think this is a Locale issue; it is APPLICATION PREFERENCE, even if there is an OS setting for it.

I personally need this feature because the calendar must match a week view that I am displaying.  That view starts on Monday.  For my clients, businesses apps want their calendars starting on Monday, and personal apps would be split between Sunday and Monday.

There is not 1 third party Calendar widget that does not allow this option.  Frankly, I would use one of them but I am trying to keep my code base size small.

I would understand if the SWT team decided that this needs to be rendered as native only, and in that case I can see why there is no option; In that case WONTFIX would be an appropriate resolution.  But if there is a fallback calendar that is already implemented, I don't see the harm in using it if the application preference does not match the system setting.
Comment 8 Lakshmi P Shanmugam CLA 2017-07-03 01:31:41 EDT
Bug triaged, visit https://wiki.eclipse.org/SWT/Devel/Triage for more
information.