Saturday, December 05, 2009

Quick Access to iPod Controls In Any Application & On Lock Screen | iPhone Alley

Quick Access to iPod Controls In Any Application & On Lock Screen | iPhone Alley
double clicking the "Home" button on your iPhone brings up a set of controls for volume, skipping tracks, and pausing your music without leaving the current application. There's even an "iPod" button that takes you right to the iPod application. But the fun doesn't stop there, so read on for more "Home" button tricks.

In addition to bringing up iPod controls from the home screen and other applications, you can also access iPod controls from the "Slide to unlock" screen. Wake up your iPhone by pressing one of the two buttons, then double click the "Home" button. A set of iPod controls will appear below the clock and give you access to play/pause, skip/repeat, and volume controls.

The last cool thing double clicking the home button does actually has nothing to do with music at all. By default, when no music is playing, double clicking the home button will actually bring up your Favorites list in the Phone app. This is extremely helpful when you need quick access to your phone from another application.

The "double click" feature can be customized from the Home Button preference page in Settings under General.


Wednesday, December 02, 2009

how to make Universal Binary static library for iPhoneSimulator and iPhoneOS

<span class="pun"></span><span class="pln">From man page of lipo:
The lipo command creates or operates on ``universal'' (multi-architecture) files.
It only ever produces one output file, and never alters the input file. The oper-
ations that lipo performs are: listing the architecture types in a universal file;
creating a single universal file from one or more input files; thinning out a sin-
gle universal file to one specified architecture type; and extracting, replacing,
and/or removing architectures types from the input file to create a single new
universal output file.

Example:
<font face="monospace">lipo -arch armv build/Release-iphoneos/libMylib.a -arch i386 build/Release-iphonesimulator/libMylib.a</font></span><font face="monospace"><span class="pln"> </span><span class="pun">-create -</span><span class="pln">output libMylib.a</span><span class="pln">
lipo -detailed_info libMylib.a
</span></font><span class="pln"></span>
Note:
-arch (armv|i386) can be omitted. lipo can figure out the architecture automatically.
-create and -output options have to be used to create a new Universal Binary static library.



Wednesday, November 18, 2009

Fading Default.png when iPhone app starts

Michael Burford's Lame Blog: Fading Default.png when iPhone app starts
More iPhone code. I wanted to have the startup logo (Default.png) graphic fade into the first screen after the program starts. This is a much nicer transition than just letting the view switch instantly.


Monday, November 02, 2009

File Signatures Table

File Signatures
This table of file signatures (aka "magic numbers") is a work-in-progress. I have found little information on this in a single place, with the exception of the table in Forensic Computing: A Practitioner's Guide by T. Sammes & B. Jenkinson (Springer, 2000). Other useful and reasonably current sources are C.E. Codere's File Format site or the magic file commonly available with Linux systems. This table is still growing and contributions are welcome! Comments and queries can be sent to Gary Kessler at kumquat@sover.net.


Monday, September 14, 2009

iPhone Font List

A lot of web pages and blogs have the iPhone font list, but they usually don't list the actual font name you have to use to create the font in iPhone programs. Here is the list that I found the hard way.

iPhone Font List
@"HiraKakuProN-W3",
@"Courier",
@"Courier-BoldOblique",
@"Courier-Oblique",
@"Courier-Bold",
@"ArialMT",
@"Arial-BoldMT",
@"Arial-BoldItalicMT",
@"Arial-ItalicMT",
@"STHeitiTC-Light",
@"STHeitiTC-Medium",
@"AppleGothic",
@"CourierNewPS-BoldMT",
@"CourierNewPS-ItalicMT",
@"CourierNewPS-BoldItalicMT",
@"CourierNewPSMT",
@"Zapfino",
@"HiraKakuProN-W6",
@"ArialUnicodeMS",
@"STHeitiSC-Medium",
@"STHeitiSC-Light",
@"AmericanTypewriter",
@"AmericanTypewriter-Bold",
@"Helvetica-Oblique",
@"Helvetica-BoldOblique",
@"Helvetica",
@"Helvetica-Bold",
@"MarkerFelt-Thin",
@"HelveticaNeue",
@"HelveticaNeue-Bold",
@"DBLCDTempBlack",
@"Verdana-Bold",
@"Verdana-BoldItalic",
@"Verdana",
@"Verdana-Italic",
@"TimesNewRomanPSMT",
@"TimesNewRomanPS-BoldMT",
@"TimesNewRomanPS-BoldItalicMT",
@"TimesNewRomanPS-ItalicMT",
@"Georgia-Bold",
@"Georgia",
@"Georgia-BoldItalic",
@"Georgia-Italic",
@"STHeitiJ-Medium",
@"STHeitiJ-Light",
@"ArialRoundedMTBold",
@"TrebuchetMS-Italic",
@"TrebuchetMS",
@"Trebuchet-BoldItalic",
@"TrebuchetMS-Bold",
@"STHeitiK-Medium",
@"STHeitiK-Light"

Wednesday, September 09, 2009

How to install fonts in Ubuntu

How to install fonts in Ubuntu? - Page 13 - Ubuntu Forums
1. Copy your TTF files to ~/.fonts (create the dir if it doesn't exist). Yes, that's .fonts, with a dot.

2. Open a console and run fc-cache -fv ~/.fonts



Tuesday, June 30, 2009

One liner for setting up passwordless ssh


cat ~/.ssh/id_rsa.pub | ssh userid@hostname.com 'mkdir -p .ssh && touch .ssh/authorized_keys && cat - >> .ssh/authorized_keys'


Just replace the userid and hostname.com as needed.

Friday, April 24, 2009

JavaScript: The Good Parts

JavaScript: The Good Parts

I found a really nice video lecture on JavaScript. I’m a JavaScript journeyman myself so I decided to review it to learn something new. I have written about JavaScript in the past — the previous post on JavaScript was “Learning JavaScript through Video Lectures“.


Friday, February 20, 2009

uFlirt -- yet another flirting tips app for iPhone/iPod Touch AppStore

You go into a bar and see a beautiful girl but you don't know what to say. Let this application help you with witty pickup lines from the pros. It also features romantic language lines in French, Italian, Korean and Chinese. Buy it now for 99 cents at the AppStore!!!

http://fasvomobile.com/uflirt/

Thursday, February 19, 2009

PegJump Soutions for all starting positions

Recently, I was addicted to this iPhone/IPod Touch game called PegJump.
I managed to find a set of solutions for all possible starting positions, and I wanted to share them with anyone who's interested.

There are total 15 pegs on the board, which means there are 15 different starting positions.
However, you'll easily find that a lot of starting positions are essentially equivalent to each other by either rotating or flipping the board. I found that the following four starting positions are enough to cover all possible starting positions.






Sunday, November 30, 2008

Ignore Files and Directories in Subversion

Ignore Files and Directories in Subversion
If you work with version control systems like subversion (svn) I'm sure you can relate to the problem of having test files show up when you try to commit changes. It is actually pretty simple to tell subversion ignore directories or specific files.

You can do this by editing the svn property called svn:ignore as follows:

svn propedit svn:ignore ./some_path

When you run that command svn will open your text editor, and this is where you can define patterns or specific files to ignore. If you place a * in the property file, it will ignore all files in the directory you specified ./some_path

Sunday, November 09, 2008

Codesign error: no certificate for identifier "iPhone Developer" was found in your keychain

Apple - Support - Discussions - code sign error (beta 5) and a ":" ...
Codesign error: no certificate for identifier "iPhone Developer" was found in your keychain august

Btw, first thing is to show the "build transcript" -- it's the little icon to the right of the yellow exclamation point ("Show or hide existing warnings"). It shows exactly what xcode is running and what those apps are returning. I think xcode's error message parsing / display is buggy -- /usr/bin/codesign was reporting the full identity I was trying to use: "iPhone Developer: MyFirstName MyLastName", I don't know why xcode kept saying only "iPhone Developer". The xcode Code Signing Build properties ui is also buggy, lots of reports of having to restart, clear fields. Remember "Target" build settings override project settings.

Anyway, as mentioned in the message below, turning Off "CRL checking" (in Keychain Access > Preferences > Certificates) fixed the codesign "iPhone Developer" error. When I next clicked Build and Go in xcode, I was asked to login to my keychain (or something like that) and then the app was transferred to my iphone

http://lists.apple.com/archives/Apple-cdsa/2008/Jul/msg00010.html

Monday, November 03, 2008

Perian - The swiss-army knife of QuickTime® components

Perian - The swiss-army knife of QuickTime® components
Perian is a free, open source QuickTime component that adds native support for many popular video formats.

Perian enables QuickTime application support for additional media:
  • File formats: AVI, DIVX, FLV, MKV, GVI, VP6, and VFW
  • Video types: MS-MPEG4 v1 & v2, DivX, 3ivx, H.264, Sorenson H.263, FLV/Sorenson Spark, FSV1, VP6, H263i, VP3, HuffYUV, FFVHuff, MPEG1 & MPEG2 Video, Fraps, Snow, NuppelVideo, Techsmith Screen Capture, DosBox Capture
  • Audio types: Windows Media Audio v1 & v2, Flash ADPCM, Xiph Vorbis (in Matroska), and MPEG Layer I & II Audio, True Audio, DTS Coherent Acoustics, Nellymoser ASAO
  • AVI support for: AAC, AC3 Audio, H.264, MPEG4, and VBR MP3
  • Subtitle support for SSA/ASS and SRT

Tuesday, September 30, 2008

Customize Your Project Build Process : Visual Studio Hacks

Customize Your Project Build Process : Visual Studio Hacks
While the Visual Studio build process is familiar for all .NET developers, not everyone realizes the build customization capabilities that can be accomplished with just a little work. You can easily put together tasks that occur before, after, and even during a build.

Saturday, September 27, 2008

Tetris AI

Tetris
This article describes how a computer can play the classic video game Tetris by getting information about the board, determining good actions, and performing those actions.
This article includes software capable of playing Tetris in real time.
The software includes the best real-time Tetris-playing algorithm in the public domain.

Thursday, September 25, 2008

Sending SMS using emails

T-Mobile:phonenumber@tmomail.net
Virgin Mobile:phonenumber@vmobl.com
Cingular:phonenumber@cingularme.com
Sprint:phonenumber@messaging.sprintpcs.com
Verizon: phonenumber@vtext.com
Nextel: phonenumber@messaging.nextel.com
US Cellular: phonenumber@email.uscc.net



SunCom: phonenumber@tms.suncom.com



Powertel: phonenumber@ptel.net



AT&T: phonenumber@txt.att.net



Alltel: phonenumber@message.alltel.com



Metro PCS: phonenumber@MyMetroPcs.com

Tuesday, September 23, 2008

Good awk tutorial

AWK Tutorial with Examples, AWK Reference
AWK Tutorial, Learn AWK

The awk utility interprets a programming language that makes it possible to handle simple data-reformatting jobs easily with just a few lines of code.

Very good SED tutorial with examples

SED Tutorial with examples
SED Tutorial

* The sed utility is an "editor"
* It is also noninteractive. This means you have to insert commands to be executed on the data at the command line or in a script to be processed.
* sed accepts a series of commands and executes them on a file (or set of files).
* sed fittingly stands for stream editor.
* It can be used to change all occurrences of "SAD" to "SED" or "New York" to "Newport."
* The stream editor is ideally suited to performing repetitive edits that would take considerable time if done manually.

Friday, September 12, 2008

good ffmpeg tutorial

ffmpeg audio/video manipulation
This tutorial should enable you to install ffmpeg and the auxiliary libraries that will give ffmpeg support for various codecs. It'll then go on to explain the basics of what a video file is, how it's created by ffmpeg and how a media player takes it apart again to display the picture and give you the sound. Next, you'll find out how to influence the way the data is produced. Finally, I'll deal with more advanced topics such as merging several sources and introducing time differentials.

Thursday, September 11, 2008

HOWTO: Compile the latest ffmpeg and x264 from source - Ubuntu Forums

HOWTO: Compile the latest ffmpeg and x264 from source - Ubuntu Forums
ffmpeg is a versatile video tool used to encode and convert a multitude of video and audio formats. x264 is a library used to encode H264 video and creates excellent looking video usually superior to xvid and other popular codecs. x264 is used by Avidemux, GordianKnot, VLC Player, MEncoder, and Handbrake.

Although ffmpeg and x264 are available in the Ubuntu repositories, you may need to compile from source. For example, the ffmpeg-user mailing list requires that you use the latest ffmpeg svn before asking for help. Since ffmpeg and x264 are updated frequently, you may also like to have the bleeding-edge for encoding videos. Also, ffmpeg in the Ubuntu repository may not support all of the codecs and formats that you may need.

This tutorial was tested on a command-line install of Ubuntu Hardy Heron (8.04) on a Pentium 4 3.0 GHz with 2 GB RAM using ffmpeg and x264 source files retrieved on May 7, 08. It was also tested in a standard Hardy Heron installation in VirtualBox.