Dali Clock for OSX

Stick a fork in it, it's done: Dali Clock for OSX, binary and source.

Requires MacOS 10.4.0 or newer (if you try to run it on an older version, it will now display a dialog box instead of just crashing.)

I expect those of you in the western hemisphere to all be running this in full-screen "countdown" mode at your parties tonight!

Tags: , , ,

34 Responses:

  1. tkil says:

    Thanks for the port -- we definitely will use it for a countdown tonight (although there was some question about whether the "count down to 12:00:00 AM" includes the leap second or not.)

    A few things that came up in my quick run:

    1. It doesn't play well with Desktop Manager: it shows up on all desktops. Granted, DM is a big hack, but it's the best answer I've found so far for virtual desktops on OSX.

    2. Full-screen mode is not transparent. Intentional?

    3. Switching out of full-screen mode, the (once-again transparent) window is the same size as full screen -- and there doesn't seem to be any obvious way to size it back down.

    4. Restarting the program lost some of its settings: countdown v. normal, just time v. date/time alternating. Granted, this provided a workaround to the problem in (3), but...

    Anyway, thanks again, and have a good new year!

    • tkil says:

      4. Restarting the program lost some of its settings: countdown v. normal, just time v. date/time alternating. Granted, this provided a workaround to the problem in (3), but...

      Forgot to mention: as soon as I opened the preferences pane after restarting, it picked up those settings again.

    • joe714 says:

      It shouldn't matter, the leap second happened a few hours ago at 23:59:60 UTC simultaneously in all timezones. It doesn't happen at 23:59:60 in each individual timezone.

    • jwz says:

      I think that "switching out of full screen doesn't restore the original size" thing only happens the first time you run it: if there's a window size saved in preferences already, it seems to respect it. I'm not sure what's going on there.

      Yes, it's intentional that full-screen mode is not transparent. I believe that's the only way to hide the menubar.

      • tkil says:

        Ok, this is the only one left that I can still reproduce.

        1. Start clock, make sure "hide title bar" pref is selected

        2. Cmd-F for full screen

        3. Cmd-F to cancel full screen

        4. Clock is now back to transparent, but is the same size as my screen (and off-center, with lower-left corner in same place as original)

        Does that sound familiar at all?

        Doing the same sequence with title bar showing behaves as expected.

    • jwz says:

      I can't offhand think of a reason it doesn't work with desktop manager; the window looks to me like it's being created in a normal way. I don't use DM, since I've never liked virtual desktops even on Linux, so I'm afraid I can't bring myself to install it just to try and debug this... but if someone else figures it out, feel free to send me a patch...

      • tkil says:

        And now I can't reproduce this myself. For all I know, I was using the "switch desktops and move the active window to the next screen" shortcut, instead of just "switch desktop". (Combine that with "always float on top" and I can see that happening.)

        Sorry for the false alarm.

        (Although I'm surprised to hear that you don't like virtual desktops -- I find all the extra padding that OSX loves to put around everything, along with a relatively small laptop screen (TiBook, 1280 x 854) means that I would barely be able to function without the virtual desktops.)

        (Also also wik: Desktop Manager is very compact, and it doesn't even have to be installed; just run it, then quit when you're done. A moot point, since I seem to have been drunk when I posted that non-bug. Sorry again.)

    • jwz says:
        4. Restarting the program lost some of its settings: countdown v. normal, just time v. date/time alternating. Granted, this provided a workaround to the problem in (3), but...

      I can't reproduce this. More details please?

      • tkil says:

        I can't reproduce this one, either. I swear, I didn't think I was drunk when I posted my original comment...

        The one thing I can still fix with a restart is the "wrong size coming back from full-screen with no title bar" issue that I mentioned above... but turning on the title bar fixes that too.

  2. joe714 says:

    If you have it running without a title bar and toggle it between full screen and windowed mode, it disapears coming back from full screen. Seems to do the right thing if the title bar is turned on though.

    • jwz says:

      What I was seeing is that if the titlebar was turned off, then coming out of full screen left the window really big (instead of shrinking it back down, as it does if the title bar had been turned on.)

      I don't see it disappearing. Can you reproduce that? More details?

      • joe714 says:

        On second thought, I may have had it set with the background transparent. I just tried again, and got what you described.

        I had it parked in a small windows in the upper right corner. When it came back, it was filling the same spot with no digits, but when I dragged it down it just had 99% of the window off screen fullsize.

  3. defenestr8r says:

    stop fucking around on your computer and glue yourself to your girlfriend already!

  4. usufructer says:

    Well done.

    It would be convenient if escape and/or the spacebar would knock it out of full screen mode. And getting rid of the mouse pointer when in fullscreen would be super.

    I'll give you a cookie if you can make it sit transparent full screen over the iTunes visualizer in full screen.

  5. gytterberg says:

    ...full-screen "countdown" mode at your parties tonight

    We did just that. I thought it was my friend's idea until I saw this post. Thanks. Otherwise we would have all been looking at our cellphones or something lame like that.

  6. mouseworks says:

    Command M makes bonk sound.

    • jwz says:

      I don't know what the usual keybindings are supposed to be. I gather you are saying they are wrong?

      • mouseworks says:

        I just hit the hide title bar in preferences. Now, I'll try it again. Nope. Now it's like full screen sized transparent but can be moved off this window.

        The new instance is about one inch high and five inches wide, without the title bar. Now, I will make it full screen by hitting f. That's not transparent, is almost full screen, but can be moved. m doesn't minimize it. q quits it.

  7. riffraff says:

    very nice. in no-titlebar mode is it possible to enable the zoom item in the window menu? that way after the title bar is nixed you can still zoom the window to maximum size? sort of full-screen-except-with-menubar mode.

    thank you jamie. and good job getting up to speed on cocoa so quickly. you're an inspiration to us all. i will have to look at the source code.

    • jwz says:

      Most of the credit for this port happening so fast goes to Ken Ferry -- he's been putting up with my dumb questions for days! It probably would have taken me forever to figure out the preferences stuff without his help...

  8. johnreen says:

    Finally, in 2005...

    Just barely, though...

  9. cliph says:

    Why not a universal binary?

    • jwz says:

      What's a universal binary?

      • pete23 says:

        the format that contains both PPC and intel code within the binary, for the endless painful CPU transition.

        i'd hope that anyone wanting it on intel at this early stage would be in a position to compile it up for themselves, but you never know...

        • wootest says:

          Apple is about to start producing Macs with Intel's chips in them, most probably Intel Core ("Yonah") and/or That New Architecture, and their first such Mac will be shipping before June. Recently, there's been rumors to the effect that they'll actually introduce some new Intel-based Macs on the MacWorld Expo trade show in early January already. In any case, making software that can run on Intel is a good idea, and I suppose you can say that it's getting better every day now.

          Apple call a fat binary compiled for both x86 and PowerPC specifically a "Universal Binary" - probably to ease the work for customers looking for new versions. OS X on Intel contains a binary translator called Rosetta that can be used to run some (but far from all) PowerPC applications; however, it's especially slow for things that require a lot of UI interaction and would probably not get along very well with Dali Clock.

          How to make the Dali Clock project produce a Universal Binary, in a few easy steps:

          1. Open the Dali Clock project.
          2. In the "Groups & Files" list to the left, double click the top row (it says DaliClock and has an Xcode project icon). A window called 'Project "DaliClock" Info' will pop up.
          3. Where it says "Cross-Develop Using Target SDK", pick "Mac OS X 10.4 (Universal)".
          4. Change to the Build tab.
          5. Where it says "Configuration" (at the top), change to "Deployment".
          6. Where it says "Collection", pick "Architectures" (right below "General" in the menu of choices).
          7. In the table below, double click "Architectures".
          8. Check both "PowerPC" and "Intel" from the sheet that shows up, and click OK.
          9. Close the Project Info window.
          10. From the Project menu, choose Set Active Build Configuration → Deployment.
          11. From the Build menu, choose Build.
  10. Window size gets jacked up.

    1)Hide title bar.
    2)Go full screen

    When you come back the window is all big and stuff.

    How about Pin to Desktop mode?

  11. I see that the clock freezes while the program is docked. This is useful if you want to know at exactly what time you clicked the yellow button, but... it would be slicker and more mac-like if the docked clock icon kept going. Dual purpose: you get a clock-in-the-dock as well as a screen saver, no?

    • jwz says:

      The animation is way too CPU intensive to be doing it while it's iconified just to update the dock icon. It'd be too small to see, anyway (unless you're one of those crackheads with the 3" dock icons).