Adium

Ticket #8989 (closed defect: worksforme)

Opened 2 years ago

Last modified 2 years ago

Adium 1.2.1 sometimes use 12h time format instead of 24h

Reported by: PRe Owned by: iheartny
Milestone: Adium 1.2.4 Component: Adium UI
Version: 1.2.4b1 Severity: regression
Keywords: Cc:
Patch Status:

Description

Please look at the screenshot. In the adium window on the rigth, we could see that adium timestamp sometimes display 7:20 instead of 19:20. On the left of the picture, you have the real history file, with good time display.

For information: I'm using french version of Adium and of Mac Os X 10.5.1

Attachments

Image 2.png (63.6 KB) - added by PRe 2 years ago.
screenshot
24h time.png (114.7 KB) - added by beej 2 years ago.
24h no workie :(
yyy.png (56.4 KB) - added by Harry_The_Bustard 2 years ago.
still busted with 1.2.3.png (165.2 KB) - added by beej 2 years ago.
advanced prefs.png (63.1 KB) - added by beej 2 years ago.
adium24h.png (58.0 KB) - added by jas8522 2 years ago.
24h format works great!
medium length preference.png (84.3 KB) - added by jas8522 2 years ago.
Setting the Medium length format is important - that is the one that Adium uses.

Change History

Changed 2 years ago by PRe

screenshot

  Changed 2 years ago by jas8522

  • owner changed from nobody to iheartny
  • milestone set to Needs dev review

Interesting... it's by design to be like that in the status message, but in actual message titles, I believe that time should follow the set format in Adium prefs.

iheartny: since you're still actively working on Stockholm, perhaps you could take a look at this?

  Changed 2 years ago by Harry_The_Bustard

The date and time in Message Titles are fine - matching what's in the Apple Menu Bar subject to the "Time Stamp Format" in the "Advanced / Messages / Message Display" Preference. However, the design (mentioned) of the Status message - i.e. the time shown to the left when events such as contacts go idle et cetera - is a bad one as it is inconsistent in that it differs from the Message Titles one. It should match that (and so that used in the Apple Menu Bar) subject to the Preference mentioned above - hence where a 24 hour clock is in use, with or without seconds, that format should be used.

  Changed 2 years ago by jas8522

  • status changed from new to closed
  • resolution set to wontfix

Harry_The_Bustard, if you'd like to fix that, go right ahead, but it's not as easy as you would think since then both the time and the status text could be of varying size... at the moment if you make it display any format of time then they will simply get clipped which looks considerably worse than a slight inconsistency.

  Changed 2 years ago by Harry_The_Bustard

My programming skill lay only in databases - and non-GUI at that - so I'm afraid I can't help here. I'm disappointed that the 24 hour clock format - without seconds at least - cannot be accommodated given that 10:00 through to 12:59 appear without being clipped. Surely this demands further consideration.

  Changed 2 years ago by evands

  • status changed from closed to reopened
  • resolution wontfix deleted

jas, I don't understand your explanation. In the picture shown, the outgoing time is shown in 12 hour time while in the incoming time is shown in 24 hour time... and the time on-hover is shown in 12 hour time.

  Changed 2 years ago by evands

  • status changed from reopened to closed
  • resolution set to fixed

(In [22511]) Don't ever force 12 hour time. Fixes display of 24 hour time in Stockholm. Fixes #8989

  Changed 2 years ago by evands

  • milestone changed from Needs dev review to Adium X 1.2.2

  Changed 2 years ago by evands

(In [22512]) Merged [22511]: Don't ever force 12 hour time. Fixes display of 24 hour time in Stockholm. Fixes #8989

follow-up: ↓ 10   Changed 2 years ago by iheartny

Fixed? If we going to use %time% then the time stamp will be too large for the design which only supports 4 characters plus colon XX:XX.

in reply to: ↑ 9   Changed 2 years ago by evands

Replying to iheartny:

Fixed? If we going to use %time% then the time stamp will be too large for the design which only supports 4 characters plus colon XX:XX.

I don't see any part of the design which fails to account for a time string of any length. What problem do you see?

  Changed 2 years ago by iheartny

the status time stamp is limited to a 39px area without a structure overhaul.

  Changed 2 years ago by evands

  • status changed from closed to reopened
  • resolution fixed deleted

Ah. I didn't change the status timestamp; I just fixed the incoming and outgoing messages. The status timestamp is still broken, then.

  Changed 2 years ago by evands

  • status changed from reopened to closed
  • resolution set to fixed

(In [22514]) Added %shortTime% keyword, which uses the localized date formatter without AM/PM or seconds, and made use of it in Stockholm for status message timestamps. Fixes #8989

  Changed 2 years ago by iheartny

Thats perfect! I may need to make one change to make sure there is no overlap between the User Name and the time stamp in the message header.

Changed 2 years ago by beej

24h no workie :(

  Changed 2 years ago by beej

this doesn't seem to work for me with 1.2.2b1 :(

see attached screenshot.

Changed 2 years ago by Harry_The_Bustard

  Changed 2 years ago by Harry_The_Bustard

It's a step back in my view - I now seeing "19 Feb" against Status Messages where I used to see a time. (That was a 12 hour one when a 24 hour one would have been better - the original issue.) I have not changed my Menu Bar time since before Version 1.2 - in that I having a Custom setting of "day dd Month yyyy hh:mm:ss - e.g. Tue 19 February 2009 22:09:59. I tried the two alternatives of the "Advanced / Messages / Message Display / Time stamp format" Preference - one with seconds and one without - but, much as expected, neither affected this as presumably that only controls Message Titles. See the attached.

  Changed 2 years ago by evands

  • status changed from closed to reopened
  • resolution fixed deleted
  • severity changed from normal to regression
  • milestone changed from Adium X 1.2.2 to Adium X 1.2.3

follow-up: ↓ 29   Changed 2 years ago by boredzo

Note that the time format that Adium uses is not the one you set for the menu-bar clock, but the one you set in the International pane of System Preferences. You can set the menu-bar clock any way you want, and it won't affect Adium (with bug or without).

  Changed 2 years ago by Harry_The_Bustard

The method I use to set the time format as mentioned above does make a difference. Here is what I do (or, rather, did) to set it so.

System Preferences -> International -> Formats

- Click on the "Customize..." option by "Dates"

- Choose "Long" from the drop-down list by "Show"

- Copy the Date shown to the Clipboard

- Click on "Cancel".

-

- Click on the "Customize..." option by "Time"

- Choose "Medium" from the drop-down list by "Show"

- Paste the Clipboard contents ahead of the Time shown

- Place a space between the Date and Time elements

- Click on "OK".

Note that he "Region" at the top of the pane is set to "Custom" by the system.

Adium shows "19 Feb" against Status Messages as per my attachment. It also shows a "Time stamp format" of "19 February 2008 22:09" in Preferences / Advanced / Messages / Message Display with another option to show it with seconds. This, incidentally, illustrates another bug in that the chosen value is truncated on the right. I'll log this if no-one else does by the time this one is closed again.

If one reverts to a standard Menu Bar display of "Tue 22:09" by setting Region in "System Preferences -> International -> Formats" to, say, "United Kingdom", the time element of that appears in the Status Messages exactly as shown - which is what's needed.

So, the usage of custom dates is presumably the root cause of the problem.

  Changed 2 years ago by PRe

For me, the problem is now solved in Adium 1.2.2: The time format seems to be always correct now (I was using French default time format).

Thanks a lot for your support! :)

  Changed 2 years ago by evands

  • status changed from reopened to closed
  • resolution set to fixed
  • milestone changed from Adium X 1.2.4 to Adium X 1.2.2

Harry_The_Bustard, if you put date information in your time format, it's your own fault that you see dates when you want to see times. There's nothing we can do about insane settings.

  Changed 2 years ago by Harry_The_Bustard

I see nothing insane about wanting to see the day, date and time in the Menu Bar. If there is a way of doing this then please let me and others know here. Whether there is or there isn't it beggars belief that the development team can't cater for such. All you have to do is get the time from the system and display it in hh:mm format - child's play by the sound of it - so the method you are using must be insane.

  Changed 2 years ago by Harry_The_Bustard

r/If there is a way/If there is a better way/

  Changed 2 years ago by Harry_The_Bustard

Incidentally, the "insane" method I used to set the time (and day and date) in the Menu Bar was given in response to a letter asking for such in MacUser - a leading UK Apple magazine - sometime last year. It means one doesn't have to click on the time or invoke Dashboard with a clock on it or have iCal in the Dock or be running Entourage with the calendar page visible et cetera to see the day and date. I like the method as - and so do the people that I've shown it to - as it makes life that little bit easier.

  Changed 2 years ago by evands

hh:mm isn't the localized time format, though it might be. We say to the system, "Please give us the short localized time format string." If that return value has been forced to include the date, that's not our fault.

I use ObjectPark's excellent  MenuCalendarClock to have access to the date, time, and my iCal events and todos from the menu bar. This inexpensive shareware is a better solution than confusing any program which expects sanity from the localized time-only format string.

  Changed 2 years ago by Harry_The_Bustard

Mac OS X, like Apple, is not perfect - clearly illustrated here by the awkward means of setting up a Menu Bar as one would wish. You would think that they would provide an option on the "Clock" page of the System Preference "System / Date & Time" to display the date as well as the time and the (abbreviated) day of the week. (It's also clearly wrong to have the option "Show the date and time" at the top of that when the date is not controllable via it.) I am not, as I have mentioned before, at all familiar with the language used in Adium but the one I am skilled in (which is embedded in an obscure RDBMS) allows the system date to be obtained and displayed in more forms than one can shake a stick at. It is surely possible to do most anything with dates and times in any language - for example identifying an HH:MM pattern in a string. So, if you can't get that simple string directly (which I find odd) then you should perform an extraction of it after carrying out a pattern match. The degree of coding for such should be minimal - as it is in the language I know - and I would be amazed if there's not a library routine for doing just that somewhere. (If not then perhaps one needs writing.) I'll look at the suggestion of using something other than a System Preference for the day and date in my Menu Bar but even if I opted for that I would hope that someone on your development team can achieve what's needed as suggested. If not then perhaps I'll have to learn the language and provide the solution myself.

  Changed 2 years ago by evands

Attempting to extract hh:mm from the localized format string defeats the purpose of it being specific to the locale. My country might display minutes first or use a different character to separate hours and minutes.

It would be better to modify the format used by the menu clock directly. I suspect you could add the NSTimeFormatString you want to its preferences (rather than to the global preferences) to get the desired effect.

  Changed 2 years ago by Harry_The_Bustard

And they say they can do anything with computers these days. Sigh. I give up.

in reply to: ↑ 18   Changed 2 years ago by beej

Replying to boredzo:

Note that the time format that Adium uses is not the one you set for the menu-bar clock, but the one you set in the International pane of System Preferences.

thanks! that was indeed where i was confused.

FYI: i filed  rdar://5763199 (having two places to set the time format is confusing) with apple.

  Changed 2 years ago by beej

arg. now that i've correctly set the system-wide time format, times show up in 24-hr format in programs like iCal, but still no love from Adium :( using the Stockholm Message Style that comes with 1.2.3, messages are currently being stamped, eg, 8:20:45 instead of 20:20:45.

Changed 2 years ago by beej

  Changed 2 years ago by Catfish_Man

  • status changed from closed to reopened
  • resolution fixed deleted

  Changed 2 years ago by jas8522

beej: do you have an override set in Advanced Preferences > Messages?

  Changed 2 years ago by Robby

  • milestone changed from Adium X 1.2.2 to Adium X 1.2.x

This shouldn't remain in the 1.2.2 milestone if it's still an issue.

  Changed 2 years ago by jas8522

  • pending changed from 0 to 1
  • milestone changed from Adium X 1.2.x to Needs feedback from users

Actually it needs feedback... my question was:

beej: do you have an override set in Advanced Preferences > Messages?

As this seems to work fine for everyone else.

  Changed 2 years ago by beej

hi, jas8522.

it looks to me like i once configured an override, but disabled it. see attached.

Changed 2 years ago by beej

  Changed 2 years ago by jas8522

  • version changed from 1.2.1 to 1.2.4b1
  • pending changed from 1 to 0
  • milestone changed from Needs feedback from users to Adium X 1.2.5

  Changed 2 years ago by jas8522

I finally got around to testing this by setting the time in the International prefs. The results show that it works without issue. See my screenshot.

When you are configuring the 24h time format, you need to be sure to set the "Medium" one - as that is the one that Adium grabs. Technically you should be setting all of them anyway - if that is the format you like.

See the second screenshot to understand what I mean.

Changed 2 years ago by jas8522

24h format works great!

Changed 2 years ago by jas8522

Setting the Medium length format is important - that is the one that Adium uses.

  Changed 2 years ago by Harry_The_Bustard

I'm pleased to see a solution is on its way - especially as I thought the gauntlet I'd thrown down would not be picked up up after it had been stamped on. Still, I'll reserve judgement and look forward to seeing the outcome on the relevant (hopefully next) release. (I'm sorry to sound cynical only I've worked in commercial software development for twenty years and seen bugs come and go and come back again - though never mine of course!) By way of a side-note it would be handy if Apple were to illustrate where the Short, Medium, Long and Full time formats are used - at least in their software. (We now know which one Adium uses - though the question "Why the 'Medium' one?" arises.) "Choosing date, time, and number formats" in the Help system has a stab at it but it's still rather lacking. Of course I realise this isn't a forum so I won't expect answers here.

  Changed 2 years ago by jas8522

  • status changed from reopened to closed
  • resolution set to worksforme
  • milestone changed from Adium X 1.2.5 to Adium X 1.2.4

According to what was discovered by beej, setting the time format in the menubar shouldn't have any effect on the time format in Adium. My findings concur - in that I changed the format to 24h in the clock settings and it did not show up as 24h in messages. It was not until I changed the 'medium' length international time format in the system prefs that the 24 hour time format showed in Adium.

As I mentioned before, there is no reason for someone to change the format of one length and not the others... you either want 24h formatting or you don't.

This has been tested with both the 1.2.4 AdiumBeta and 1.3svn.

I have confirmed this with Robbie and with a user on IRC.

Robbie's tests indicated that using a 24h locale setting resulted in Adium showing times in 24 hour format.

The user on IRC reported that once he changed all of those (short, medium, long, and full) to 24 hour it worked fine in Adium.

  Changed 2 years ago by Robby

Yep, and this ticket has become quite a mess anyway. So if there's an issue left please open a new ticket and it will be looked at.

Note: See TracTickets for help on using tickets.