Search This Blog

Paintbrush: make transparent background

  1. make sure you have the latest PaintBrush installed.
  2. select Fill tool in the tool panel
  3. click to set foreground color, it will open the color panel
  4. set opacity to 0%:
  5. fill the area the you want to set to transparent

Windows 7 OEM: backup and restore activation

  1. Download ABR beta for Windows 7 OEM and extract it on to a USB drive.
  2. Run activation_backup.exe in the extracted ABR folder.
  3. It will create two backup files:
     backup-key.txt: Backup license key 
    backup-cert.xrm-ms: Backup activation certificate
  4. Re-install windows 7
  5. Run the following commands to restore the activation:
    1. Open Command Prompt as Administrator
    2. Run
      slmgr.vbs /ipk XXXXX-XXXXX-XXXXX
      where replaces XXX with your Windows 7 production key which was backed up into backup-key.txt file
    3. Run
      slmgr.vbs /ilc backup-file.xrm-ms
      to restore the activation.

See also

Toshiba Satellite Pro C850 Laptop Factory Recorvery

Make sure you have back up all the data in the hard drive. It will erase the partition.
  • Method 1:
    • Restart the computer, hit the F8 key repeatly until getting into the "Advanced boot options" screen
    • Select Repair your computer then hit Enter
    • Select your country and click Ok
    • On the "System Recovery Options" screen, click Restore Application
    • Follow the instructions on screen, click Full Factory Recovery
    • Click Next then Yes
    • It will take a few minutes to finish the restoration
  • Method 2:
    • Turn off the computer, the hold 0 (zero, on top of P) key, then click the power switch button, keep hold 0 key until you hear a beep, the factory recovery should start

Mac OS X: turn off Voice Over

Key combo: command + F5 can turn on/off Voice Over.

Mac OS X: reset Universal Access (Voice Over etc.)

Remove the file ~/Library/Preferences/com.apple.systemuiserver.plist
rm ~/Library/Preferences/com.apple.systemuiserver.plist
and log out then log back in.

git: count total number of lines

  • Method 1:
    git ls-files | xargs wc -l

    or count only .java files:
    git ls-files | grep '.java$' | xargs wc -l
  • Method 2:
    git diff --stat $(git hash-object -t tree /dev/null)

去除右键菜单的“一键备份到115网盘“

  1. 在命令窗口内运行:
    regsvr32 -u %APPDATA%\115Backup\ShellExt115.dll
  2. 重启
  3. 删除
    %APPDATA%\115Backup
    文件夹




源自

Rotate screen in Windows

Use the following key combos to rotate the screen:
  • Ctrl + Alt + Up (back to orginal)
  • Ctrl + Alt + Down (180 degree)
  • Ctrl + Alt + Left (90 degree left)
  • Ctrl + Alt + Right (90 degree right)