How can I remap the power key on a MacBook Air? - applescript

I am trying to make a program that allows more flexibility in remapping keys. All of the keys are fine so far except for the power key. Is there a way to remap the location of the key itself or even just possibly disable it through terminal or applescript?
-Thanks

No, unfortunately not.
It was possible a few years ago with the tool Karabiner. However, starting with OS X 10.9 the feature was removed. See: Google: pqrs karabiner power-button

Related

Keyboard Layout Changed in System Boot For Mac OSX Firmware Passwords

I encountered this issue lately when I decided to increase the security of my Macbook Air (Early 2015) running the latest version of El Capitan (10.11.3). I'm not sure if this issue is relative for other models and/or operating system versions.
I used rather strong password with multiple special characters and since the password is confirmed by typing it twice as usually, I was pretty comfortable that I typed it correctly. My default and only keyboard layout I use with Mac is Finnish layout and this Firmware password was also written with that layout.
However when I tried to boot to my Windows installation and I was prompted with the password it never worked and I didn't get any indication of the problem. Just new password prompts.
The problem was that the default keyboard layout on system boot is not the same as the one user defines. This might be common sense for more experienced computer users, but when I tried to seek for an answer nothing came up and this was my intuition of the problem.
Bottom line is that if you are using any other keyboard layout on your osx and create firmware password with special characters, bear in mind that if this problem occurs it's probably due to this fact.

iSight/FaceTime camera not working after upgrade

right now i am running the OS X Yosemite beta 10.10, after upgrading my OS X i lost my camera, i tried everything in the forums, but nothing helped.
i can't FaceTime, or Skype or anything. normally i would take it in to an apple store, but the closest apple store to me is about 200 miles away.
since i am beta testing OS X Yosemite, i knew i was going to have some problems, but i need this to work
also; i also installed the update 2 days ago as it was recommended in the app store.
(not a hardware problem, was working perfectly before the upgrade and it is not found in the "system info> USB"); also not user specific.
Open your terminal and type this command:
$ sudo Killall VDCAssistant
Now, go to your Skype->Preferences->Audio/Video and you can see the webcam working.
Have a good one!
Apparently, this problem persists even in the recent versions of OS X Yosemite. I also had this problem. So, the answer to solve it is basically resetting the SMC, which Apple provides instructions in https://support.apple.com/en-us/HT201295
Now, I was not able to sort it even by resetting the SMC in a Macbook Pro 15 mid 2012. At least, not immediately. As I keep a few things connected in the USB ports, I believe it might have been the reason, so I closed all my applications (just in case), turned off the computer, unplugged all the USB and thunderbolt connectors (yes, including the LAN adaptor), as well as the earphone connector to speakers. THEN, reset the SMC (for non-removable battery computers, by pressing and releasing control-shift-alt-power [left shift] simultaneously while connected to power). For me, it worked.
It might be useful to remember that the SMC is the System Management Controller, that takes care of the hardware in a low-level, including i/o, keyboard backlight, speakers, camera... so, if you are going to reset it, it might make sense to release all the possible burden it might feel.
Resetting SMC is the only thing that solved the problem on my MBP Mid-2012.
The issue came about around the time I upgraded to High Sierra.
This issue is solved with the newest update of OSX Yosemite. Just update through the Appstore app and everything will be normal.

Keymap issues with NX from Mac OS X Lion [duplicate]

This question already has answers here:
Keymap issues with NX from Mac OS X Lion to Ubuntu
(8 answers)
Closed 7 years ago.
I tried to answer the question from Mark:
Keymap issues with NX from Mac OS X Lion to Ubuntu
However, it is locked so I figured I would post a new question / answer.
I have been trying to answer this for a few days now because I have no issues when connecting through NX Client (technically OpenNX) to FreeNX server from an iMac (with Lion), but if I try to connect with a Macbook Pro I get horrible keyboard binding issues.
I had the same issue (I'am on a Macbook Air with OSX 10.7 Lion) and reverting back to 0.16.0.648 fixed the problem for me too.
I'm on a Macbook Air with OSX 10.8.4. I've tried release 648, 649, and 725 of OpenNX to connect to Ubuntu 13.04. Each didn't work out of the box and even with the above trick of editing my profile's cfg, my keyboard mapping still isn't right. (The sshlog shows '--keyboard="empty/empty"')
Once connected, in all of these cases, the 'd' key minimizes all open windows, the up arrow key maximizes the current window, and the down key restores it to its original size. My point is that with all of the above attempts changing something on the Mac OpenNX client, I'm starting to think the problem is something Canonical has done with Ubuntu 13.04 and/or FreeNX. That latter doesn't look like its been updated since I had to install it from the 12.xx ppa.
As a further datapoint, even X2Go connections exhibit the exact same behavior when using the Gnome desktop. In the X2Go case, the client dialog shows using a pc105/us keyboard.
I hope this gives others something to go on. I couldn't add this as a comment so had to do it as an answer, sorry.
I had this problem with 10.7.5, the fix was to install XQuartz instead of the native X server. Well, mostly fix. The CAPS LOCK is inverted, that is, it's all caps when it's off and normal when it's on but otherwise the keyboard works with XQuartz. Installation is easy
and it didn't break anything else on the Mac. Although what is working even better for me was to load Ubuntu on the Mac, right now I have it setup dual-boot.
The fix that is working for me is to go into:
~/.nx/config/HOST.nxs
and change:
<option key="Current keyboard" value="false"/>
<option key="Custom keyboard layout" value="empty"/>
<option key="Grab keyboard" value="false"/>
I have tried this on three NX Servers and all are fixed. Hope it helps or gets you closer. Always check in the ~/.nx/temp/ for the sshlog and see if --keyboard="empty/empty" instead of "pc105/en" because the Mac is really pc104.
9:05:35: startsession --session="HOST" --type="unix-gnome"
--cache="8M" --images="32M" --link="adsl" --geometry="2556\ x1396" --screeninfo="2560x1440x32+render" --keyboard="empty/empty" --backingstore="1" --encryption="1" --composite="1" --\ shmem="1" --shpix="1" --streaming="1" --samba="0" --cups="0" --nodelay="1" --defer="0" --client="macosx" --media="0" --st\ rict="0" --aux="1"

Mac equivalent for CryptProtectData and CryptUnProtectData

I need mac (carbon) equivalent for CryptProtectData and CryptUnProtectData.
Please refrain from suggesting a cocoa solution with "move to cocoa" since that's not an option.
I'm not a Mac expert but I think you want to use the Keychain API on Mac. You might just use Keychain for storing/generating the protection key, and use the native encryption api's for en/de-crypting the file.
I ended up using blowfish algorithm from Open SSL. This worked both on Windows and Mac.

Mac/Windows Switching

About 2 years ago I dropped windows from my home PC and switched 100% to linux (fedora, then ubuntu) - The missus wasn't too happy but she got used to it and learned a thing or two. Then about 6 months ago I got myself a shiny new Macbook and since moving to OSX have never looked back; Unfortunately I've not been successful in getting my employer to buy me one for work (and I can't be carrying mine back and forth) so I have to "put up" with windows.
I started out with windows over 8 years ago so I have a really good understanding of how it works and have done my fair share of Win32/MFC/.NET development.
My question is; Who else has to use a windows box at work (and have a mac at home) And how do you cope - what windows apps/configurations do they use that let them work in a similar fashion to OSX? - I was just thinking how cool it would be if I could get some sort of keymapping app that re-mapped my windows keys to the OSX variants (Apple+W, Apple+Q, Apple+Left, Apple+Right, etc etc).
I miss expose (TopDesk is nice but not free)...
I miss the simplicity of finder...
I miss the nice smooth dialogs and windows and shadows (YzShadow can juuuuust cope)
I miss the underlying unix framework (I run andLinux at work)
I miss OSX :(
Unfortunately 90% of our clients use IE so windows is a must; They also can't justify the expense of a mac for a developer; Especially a Mac Pro :-p
Ah well.
Operating System is just a tool, if you are building cross platform applications (or web applications[it depends only your target web browser]) and you can use whatever operating system you like , you can install windows xp in virtual machine on your osx for using IE for example, but if your company forces you to login on their domain controller, using outlook for email and task management that project manager assigns to you, this is different story. As you mentioned multiple operating systems at work and home, personally I use Linux at home but I use Windows at work because in my day to day job I write a lot of C# .NET code but at home I spend time by programming with open source technologies and I use it because I've used Linux since October 2001. So try to get used to it.
Might I suggest if you like life on the command line that you try PowerShell as a replacement for cmd on the windows box. It has aided me tremendously in my transistion from a Unix Server environment.You have a profile and the ability to create aliases and modify things. Now I never have to worry about using one of my trusted Unix commands, and if I find one that wasn't already taken care of by the PowerSHell team I just create it and add it to my profile. ls, process grep, top, and find for the the win!!
I think the single best thing I've done to maximize productivity is to standardize my text editor across platforms. Personally I use vim as mush as possible. I use viemu to integrate into visual studio on windows, have replaced notepad with gvim, and I use vim on mac and linux alike.
You could remap shortcuts, but the simple ones are the same anyhow. Personally I dont have a problem remembering both. I do go through a mental exercise every few minutes to look for OS specific landmarks to remind me Im on Vista or OS X, which helps me to stay focused.
I'd also look into Powershell if you're a fan of Linux scripting, its the coolest shell going IMNSHO. Failing that there is always Interix
I don't have a lot of pain switching from one to the other on a daily basis. At the end, I spent the most of my time either in Eclipse, which is quite plateform independant, and Opera web browser.
For the rest, I use launchy to poorly mimic quicksilver and e as a replacement for Textmate.
In the end, I'm more statisfied of my mac, not because of the software it provide, but rather for the software it don't provide, such as Toad or IE that I'm force to use for my work.
Although there are many ways to skin Windows to look like OS X, none of the solutions deliver the real OS X experience. Not in terms of OS Features, that'd be impossible, but the look and feel is always different. I remember skinning for the sake of pleasure, my Windows XP box (like 5 years ago) and used Windows Blind plus a lot of tools (YZDock!) to have a "WS X" ;)
It never felt the same.
You could try a "hackintosh", if your hardware is "ok" with OS X. Then run VMWare/Parallels.
Or else, you just do like me:
Cry a river. Build a Bridge and get over it. :)
I use OS X (Mac Pro) but I code in C#, so I'm 90% of the day in Windows VIsta in Full Screen in one of the many Spaces; the advantage is that VMWare (and Parallels) let you map your keys so I can cmd-c/v inside Windows.
I understand your frustration :S
Unfortunately 90% of our clients use IE so windows is a must
IE6 works under OS X without Windows (fonts aren't quite right, but it's enough for everyday testing), and you can get it 100% perfect under virtualisation (Parallels, VMWare, VirtualBox).
As a software developer I pretty much live in my text editor and shell. In the jobs where I've been forced to use windows I install emacs and cygwin and I'm off to the races.
I don't focus on the periphery -- control panels, window managers, etc -- I focus on what I really use 90+% of the time and don't sweat the rest.
A little bit of cygwin to take the pain out of windows. Any virtual environment will work. A mac can run parallels hosting windows with the enforced outlook requirements.
If it's not a financial burden and your company allows it, just get yourself a macbook. I bring my macbook to home and work everyday. I have external 24" screen at work, and it's no difference to working on a windows box. I run parallels when I need to use windows/IE, otherwise, all my time are spent on the mac.
Another important item in this arrangement is an external harddrive for backup at work. Time machine hourly backup + windows work file sync and you're all set. This way, you don't have to worried about losing your work if you get robbed or get into an accident.
I was in the same situation - Mac at home, Windows at work. There isn't really any way to bring the Mac experience to Windows without something breaking or a badly-written program misbehaving. You just have to get used to adjusting between the two.
The only three things that constantly caught me out were hitting Shift-2 for the "#" sign in Windows (I have a UK keyboard, but the Mac uses the American key position), trying to use two fingers and a mouse click on the Windows laptop trackpad for a right-click, and hitting F9 for Expose. Swapping between Command-C and Ctrl-C didn't really bother me.
I use Windows XP at work and Mac OS X and Linux at home.
Windows XP frustrates me everyday. If I only used it I would get used to the limitations, but being exposed to them daily (and the plethora of awful software for it, from the dire Checkpoint VPN client, to the clunkiness of Outlook) and then experiencing decent software in the evening just underlines XP's limitations (and to be fair, XP is venerable these days).
However making the switch on a daily basis isn't a problem, #/" issue aside.
The only thing I ever did to make the Mac more "windows-like" was install Office for Mac. I've never had a problem with files I couldn't read or write, and the "student edition" is pretty cheap. Recently, for dealing with IE6 I used bootcamp bought and an MSDN copy of XP to install XP on partition on my Macbook. No problems.
I regularly use OSX, Windows and Linux and the only times I get confused is when I'm running XP under VMWare on my Macbook. For some reason, when my fingers are on the Mac keyboard, I have a lot of trouble using Windows key strokes.
Otherwise, no real problems.
I don't have much of an issue. I can do most of my development work in OSX, eclipse works, Coda is an awesome web development tool, but when I need to use Visual Studio, I can, either by running in Fusion, or booting into windows via bootcamp.
Having the luxury of a windows install on bootcamp means I can also run games better than most of the Windows PC's i've owned!

Resources