Where can I find a UI element of code on the internet to implement an LCD like display as in XCode 4 and iTunes.
The one in XCode 4 is a bit more advanced than the iTunes ones, it offers more functionality.
Is this a standard element, or is it a private Apple one?
It's a private Apple one. I built one for myself using a graphics program for the background and the interface builder to design the control.
I used Opacity as the graphics program and let it create the Core Graphics implementation for the background. That way I can even change the color of the background and it's easily resizable.
Related
I'm developing a cross-platform photo retouching application based on Gtk-2 (but already able to support Gtk-3 with minor modifications).
In my program, the result of the image retouching is previewed in a scrollable area that is implemented through a Gtk::DrawingArea inserted into a Gtk::ScrolledWindow. The drawing itself is performed using Cairo.
Recently I had the possibility to test the software on a MacBookPro laptop with retina display, and I've immediately realised that the preview image gets magnified by a factor of 2, like all the rest of the GUI elements.
Is there a way to tell Cairo and the DrawingArea to use the native screen resolution, instead of applying a 2x magnification? Is this supported in recent Gtk-3 versions?
Thanks for you help.
I developed some app for iPhone/iPad, so I know the basic concepts of Cocoa programming. Now I need to write a Mac OS X application. If you help me to choose the right controls to use, I'll study the Apple documentation reference for them.
I need:
a control to show a grid of thumbnails (png images); I'll be able to change the order of the thumbnails by dragging and dropping them;
a control to show a single image (e.g. UIImageView of Cocoa Touch) with the possibility to drag and drop another image over the first one; besides I need to move and resize the second image by dragging its corners (as if corners were "anchors");
a control to browse the media files on the Mac (possibly iPhoto images, iTunes DRM-free songs, or simply the content of a given folder), like the media browser of iMovie.
I use Xcode 4.2.
You can use NSCollectionView and co. for this. Xcode has a sample application somewhere in documentation (browsing various images) as well as tutorial on how to setup NSCollectionView yourself.
Check NSImageView. You can basically find any Cocoa control alternative to Cocoa Touch just by changing UI prefix to NS.
There is no such control per-se (unless IKImageBrowser for backgrounds), but using aforementioned NSCollectionView and some API for media files you should get around pretty quickly.
Also check ImageKit framework for images (for browsing, viewing and modifying).
I'm wondering what kind of shenanigan framework or UI kit Apple used for the black QuickTime X windows.
Looking at the available options in Interface Builder, nothing seems to match.
Quicktime X
IB options
It's kinda like a HUD (gradient top bar, dark) but it's darker than a HUD and has all the standard 3 buttons. It doens't look like a Textured Window either.
Can anyone shed some light on it? How could I create a Window like QuickTime X ?
(And also the controls within the window)
It's Apple. They know how to do fancy stuff.
Go to Applications, find QuickTime Player.app, open context menu, choose "Show package contents" (or what it's called in English), Go to Contents / Resources and have a look at the images, especially titlebar-corner.png, titlebar-middle.png, … and close-active-color.png, …
Many apps which were released in these years have new looking gui parts.
Vertical layouted min, max and close buttons in iTunes or Twitter.app(But latest one has default layout) , Tab control in Safari and Terminal, sliders in GarageBand and iMovie...
I can't find these new gui parts in interface builder.
How can I use them?
see http://cocoacontrols.com/ for cocoa controls
Those new looking GUI parts belong to the individual applictions, most of them can't be accessed via API. You'd have to write them yourselves.
For some popular GUI parts there are third party libraries available however.
I have my macbook pro hooked up to an apple cinema display. I want to work on my code on the laptop but have interface builder on the cinema display. It needs to be this way because my laptop screen doesn't have the resolution to show a full iPad interface layout in IB so I would need to scroll up and down.
The thing I am fighting with is that whenever I open a XIB, or when IB starts, it places any new app windows back on my laptop screen. Is there any way to define a window layout for IB to use, and tell it to start all windows on my second screen by default? Thanks
Unfortunately Interface Builder does not currently save window positions (which include what screen they're on).
You might have limited success using Spaces, which assigns specific applications to specific spaces, but I'm not sure how it would work with multiple screens.