Since a few weeks whenever some app needs our password our needs our permission for something, it no longer displays it as understandable language, but with weird characters. How can we fix this?
It is probably a problem with your language for some inputs / options.
Look at this documentation about how to change your language for specific options:
http://support.apple.com/kb/PH11251
Depending on which version of OSX you are running, you might want to try Font Book (in the Applications folder) and specifically search for Look for Enabled Duplicates. Sometimes having duplicate or misnamed fonts can cause rendering problems like this.
There are other utilities as well, such as Font Doctor that can do similar (and more extensive) searches.
Related
When you look at information for a font in FontBook in OSX, it lists all kinds of useful information, including Language, Version, Unique name, etc. Is there a nice way to get any/all of this information from objective C? In particular, I want to get the Version of a font.
I know how to make a CTFontDescriptorRef but I don't see any attributes on it that would give me the Version. I've looked similarly at NSFontDescriptor but not found anything, and googling hasn't helped.
I need to do this because the app I work on runs in Chinese, and I know that one font looks better than another as long as I have a "late enough" version of the font installed. So I'd like to use a particular font if the later version is installed, and otherwise fall back to another font.
Well I stumbled upon the answer five minutes after posting. I was basically looking at the wrong place, hoping to find it in CTFontDescriptorRef. It looks like the right place to look is CTFontRef, which you can create from a CTFontDescriptor via CTFontCreateWithFontDescriptor.
Then you can use CTFontCopyAttribute, and a bunch of different things are available, namely kCTFontVersionNameKey.
I'm surprised no one has asked this yet. What's the best way (if any) to get a Vi experience in Xcode? I know about ViMate but TextMate doesn't come close to Xcode in terms of integration and code completion.
BTW, I am using Xcode 4.
You might want to try out xVim which seems to be an active project. The currently indicate that it works with XCode 4.2, Espresso and Chocolat. Presumably you could selectively enable it with other applications.
Here's another plugin which I made a few weeks ago.
http://programming.jugglershu.net/softwares/xvim.html
This is currently developed for personal (my) use. So you may feel bad with some lack of implementation. Give me a feed back(feature request) then. I'll add some keybinds if I have enough time.
The closest you'll get is http://www.corsofamily.net/jcorso/vi/, or configuring an external editor. This has been a long-standing deficiency with XCode. (If you ask any vi user that is..)
OSX and XCode in general favors Emacs key bindings.
More info on general key-binding strategy for OSX: http://hints.macworld.com/article.php?story=20060317045211408
Right now, I productively use XVim†. I'll probably try $20 ViCiOUS, which seems more polished; I like having source access to my tool-chain, but this is for Xcode, so c'mon me.
† Not xVim, which I just discovered, but apparently face down in the pool. In the [Xx][Vv]im namespace, Xvim (à la Xcode) would have made more sense to me. There, I said it.
Here's another choice: KeyRemap4MacBook.
I am quite familiar with MATLAB, although not so much with writing GUIs in it. Now my boss gave me a MATLAB program with GUI which was developed on a Windows machine and runs there without problems. I copied it to my mac (osx 10.6.5 with MATLAB R2009b) using a USB memory stick and tried to work on the files on my computer.
When starting the GUI, some of the callbacks are executed, some not. I was able to open the figure file containing the GUI in GUIDE, but there cannot click on the callback fields in the Property inspector. Also some components are not shown in GUIDE which are visible when running the GUI. First I suspected it might be corrupted by changed newline characters, but learned that .fig files are binary, so this should not be the case. I opened the binary .fig file with a text editor and found the following ASCII line followed by binary data:
MATLAB 5.0 MAT-file, Platform: PCWIN, Created on: Tue Aug 10 17:11:57 2010
Are the GUIs created with MATLAB OS specific? Wouldn't this be really stupid?
I opened the files on the windows machine again and tried to export them or save them by specifying that I want them to be compatible with other operating systems but could not find an option like this.
Of course I researched this on google, and wondered that I did not really find something related. If an incompatibility exists, I think this would have been discussed, right?
Anyone knows about it or had the same problem before?
Hmmm, ok. Well, the answer is quite embarrassing but still bears some potential to learn from it. The folder that my boss gave me contained a lot of files and figures with similar names, like:
bla1.fig
bla.fig
bla0.fig
the simple problem was, the first time I opened the figure with GUIDE I opened figure bla.fig instead of bla1.fig. After this I always used the reopen function of GUIDE and did not see that it was always the wrong file. this caused the problems.
==> so there is no incompatibility between Mac and PC, although I wonder why the platform is written in the file then
==> it could have been a problem with backwards-compatibility as the original figure was created with MATLAB 5
==> as #Adrian and #Mikhail pointed out: it would be very very useful to use a Version control system in order to prevent to have hundreds of files with different numbers where most of them are of no use anymore
There seems to be some incompatibilities between different platforms and also between different versions, from my experience (MATLAB 5, 6, and 7) also -- I've encountered similar situations many times.
I am not exactly sure when the GUIDE became available with MATLAB -- I first noticed about it when I was using the first version of MATLAB 7. (It used to be very unstable at first, but is very usable now. For example, I vaguely remember a critical issue with MATLAB 7 Student version. You had to download a patch to make the GUIs work.)
Does your boss know how the *.fig file was created and in which MATLAB version? Can you open the *.fig on the old version of MATLAB and display the GUI correctly?
Some functions have possibly become obsolete since the earlier version of MATLAB that was used to create the figure, and may be causing some minor problem with it. If that is the case, you can troubleshoot it by checking all the error and warning messages that appear on the Command Window (or the MATLAB Console.)
Also, you should be able to load the *.fig files on the workplace using the following command from the Command Window, assuming that the files are in MATLAB's search path.
load your_file.fig -mat
You should then see a structure dataset, and see all of the figure properties, etc. in that structure.
You can use the information to create a new figure without the GUIDE (GUI Development Environment / Tool).
I recommend you writing your own GUI app. It's not that difficult, with/without the GUIDE.
I recently opened a site with some Tips on MATLAB Programming for beginners and intermediate users, and update it in my spare time. If you have any specific question about GUI building, I may (or may not) be able to provide answers there...
I'm just curious whether there is a gui framework that alloys you to use a mac look n feel on other platforms. presumably frameworks that use native APIs wouldn't be helpful (eg wxwidgets).
qt uses native API partially for mac look n feel, so that isn't useful.
what about swing?
In general, don't do this. Different platforms have different conventions, and your software should follow its platform's conventions to minimize the cognitive load of the user.
Unless, I guess, you're the only person who you ever expect to use it.
Legally, you can't create the Mac look and feel on another platform. Apple owns the copyrights to it.
However, the Quaqua Java Look-and-feel implements Java widgets that have that look-and-feel. If you have a good reason to use it in a non-commercial way, it may be a solution.
Every operating system and desktop manager has a different way of implementing GUI elements. Trying to port an application that will look exactly the same as OSX onto these platforms will be difficult if you're looking to use the native controls. Secondly, like Gred stated, each one will have their own way of doing things and could cause user issues by having unusal icons, symbols and controls displayed or missing.
Though if you would like to attempt this, one of the multi-platform web browsers such as FireFox might be able to give you some idea of how to carry over the same general look and feel over the platforms.
Good luck, and hope this helps some.
To answer the last question, Swing does not ship with the Mac look and feel on platforms that aren't Mac-based. This also applied to the other platform-specific look and feel elements.
While not the greatest solution, for Java, the Nimbus L&F is a good alternative... but since it's now included in Java (as of 6u10), it's not available separately any more.
You can implement your own style in Qt [and probably GTK*] to attempt to look the same (see QStyle). However it probably isn't worth the time and effort and will piss off some users. There are some windows themes that attempt to mimic the look. I know the new version of parallels ships with something like that, but it looks rather funny as the margins, spacing, font, etc is completely wrong.
I'd like to build an application with a "drawer" GUI element, like it is all over the place in Mac OS X.
Is it possible to do so in Linux/Windows? Is it possible to build it crossplatform?
I like OS X drawers, but they are not used nearly as often as they used to be. The only apps that I currently use that makes use of them are OmniWeb and TextMate.
I don't think it's worth trying to recreate that UI feature for Windows or Linux. In addition to being too much work, your users likely will find it jarring.
Generally speaking, a standard sidebar ought to support whatever you might use a drawer for.
I think you'd have to roll your own drawer in Linux/Windows.
You all say that drawer is not in use "anymore", which doesn't really help. In any case, I see it fit on a TextMate perfectly, and noone complains about it :-)
KDE seems to have a drawers-like functionality as seen in KDevelop, and some other applications (Kate, the editor, uses them too), but I have never tried to use them in anything I've written, and so would have no idea how to write them.
I haven't used Osx a lot, but cant just a normal sidebar do the job?
Drawers are no long really used on the Mac. I only know of a few that still use them and most of these are older applications. Most have moved the sidebar into the app in a collapsable split view.