1. Font CSS Substitution Methods

    September 2, 2009 by J.P.

    font-image

    Many new methods of font substitution are coming of the wood work and old methods are now getting a second look.

    @font-face method

    The @font-face method was added to the CSS2 spec but then not recommended in CSS2.1. However with CSS3 it’s back and supported by most popular modern browsers. Read about @font-face at W3.org.

    This method requires the font being loaded on the server and will cause a slight flickering of the font rendering while it is stored in the cache. The plus side of this method is it’s easy to implement and requires no JavaScript.

    Here is an example of @font-face being used. Click Here

    Sample CSS code used (Note: font is stored on the server)

    @font-face {
    font-family: 'BrushScript';
    src: url('BrushScript.ttf') format("truetypefont");
    }
    /* for IE */
    @font-face {
    font-family: 'BrushScript';
    src: url(BrushScript.ttf);
    }
    body {
    font-family: 'BrushScript', helvetica; /*degrades to a standard web font if unavailable */
    font-size:1em;
    }

    Cufon JavaScript Method

    This currently my personal favorite method. No font is stored on the server and there is no flicker of the font while loading. The wizard also provides many options and settings so you can customize the needs for your site.

    Easy to add

    Cufon provides a simple method for converting fonts on your local machine into a js file that you include in the header along with the Cufon script. A simple replace call is used to substitute the font. Read more about Cufon here

    Example of the Cufon Method ยป

    Example Header Code

    <script src="cufon-yui.js" type="text/javascript"></script> <script src="AGaramondPro_400-AGaramondPro_700-AGaramondPro_italic_400.font.js" type="text/javascript"></script>
    <script type="text/javascript">Cufon.replace('h1');Cufon.replace('p');</script>

    Background Image method

    This method is good for replacing a few headers and best method to use with the logo of your site. Detailed px to px cross browser look with the design is needed while the code remains semantic. This method has been implemented in this version of my site since for major section H1 headers and the logo of the site.

    XHTML Example Code

    <h3 id="Portfolio">Portfolio</h3>

    CSS Example Code

    h3#Portfolio
    {
    background:url('/portfolio/2009/gfx/title_portfolio-trans.png') no-repeat;
    text-indent: -9999px;
    width:229px;
    height:61px;
    }

    This will work with all browsers. A list will be added shortly of the other methods and their support.


  2. CSS Adjacent Sibling Combinators With Text

    August 26, 2009 by J.P.

    siblings_01
    Here is a short and sweet post demonstrating the use of adjacent sibling combinators with text is an easy way to work with unique spacing with headers and copy in general.

    Basic Example Code
    h1 + p{
    padding:20px 0 0;
    }
    h2 + p{
    padding:0px 0 0;
    }
    h3 + p{
    padding:0px 0 0;
    }

    Here is a link with 3 different headers and style demoing how convenient this approach is.

    Eaching header has a unique spacing when followed by a <p/> tag.


  3. How to Swap Asus 1005HA Wifi Card OSX10.5

    August 22, 2009 by J.P.

    Before we begin I want to tell that you are doing this at your own risk and this will be voiding the warranty of your netbook.

    Here are a list of compatible cards I have seen mentioned online but I have only tested and verified the Dell 1510.

    • Dell 1510 Tested and working with 10.5.8
    • Dell Wireless-N DW 1500 mini PCI
    • Any Broadcom mini PCI
    • If you know of more comment or email me and I’ll update.

    Steps for card installation

    IMG_0034

    Ground yourself so you don’t short anything internally

    IMG_0035

    Flip the machine over and remove the battery

    Remove the ram cover, ram, and the silver screw.

    Remove the 4 screws in each corner

    Flip the machine back over and open the lip.

    Time to remove the keyboard

    IMG_0036

    The keyboard is held in place by 4 tabs the top directly above the F1, F6, F10, and Insert.

    With a flat head screwdriver or something else very thin click each tab and the keyboard will popout slightly.

    Once popped out slowly pull it out from top corn to top corner. (Warning there is a ribbon connecting the keyboard to the track pad so don’t just rip it out like a gorilla.)

    IMG_0038

    Once the keyboard is loose lift it up from the bottom to expose the ribbon connector. If you haven’t worked with ribbon connections before don’t worry it ain’t no thing. It was my first time to and after about 30 secs I had it under control.

    To release the ribbon you will see 2 black connectors on the left and right side. Carefully push them out towards the monitor.

    The ribbon should immediately release.

    Cool keyboard is out now time for the fun part.

    Remove the 6 screws that are holding the shell and trackpad.

    IMG_0039

    Once all 6 have been removed flip the trackpad, blue ribbon connector up. (Note this ribbon connection is different then the keyboard connector. It needs to be flipped up).

    Once screws and ribbon have been removed and released start prying thing case off. This is a major pain in the ass and you have to be a gentle giant not to just hulk the top off and break the plastic clips. I would recommend using a credit card and run it around the entire crease to help loosen things up. You will also have to focus on the tabs that are under display. There are 4 in total and harder then the rest of the tabs to loosen up.

    Once the top is off you will see all the internal components of the machine. I celebrated with a beer at this point.

    IMG_0044

    To access the wifi card you will need to release the ribbon for the SD card reader which is another flip up like the trackpad.

    Once the cable is out of the way simple unscrew the wifi card and it should become very loose and easy to pull out of the board. Gently tug the antenna off the wifi card. Removal complete.

    IMG_0050

    Get your OSX 10.5 compatible card, connect the antenna to it and insert it back in the board. Once the card and antenna are secure and screwed in reconnect the SD card ribbon.

    Rebuilding

    • Re-secure the case and make sure you have enough slack to connect the trackpad ribbon.
    • Flip the ribbon connector down making sure the ribbon is fully connected.
    • Fasten the keyboard ribbon back in and drop it back into the case starting with the bottom.
    • Flip the case back over and install the remaining screws, ram, and battery.

    Wifi Card Installed Time to See if It’s Working!

    I fumbled a few times at this stage and missed something very basic that sent me into a kext loop that wasn’t needed.

    While booting the machine go into the Ausu bios and make sure that WLAN is enabled. My wasn’t and I thought the 10.5.8 upgrade had broken the ability for the card to connect to a network.

    I booted in Chameleon with -v -f and noticed a few lines of code showing the airport id and that the card was enabled. I think they are displayed right before all the voodoo.kext files load.

    Another good sign that the card is working will be the blue wifi light always active on the bottom right of the machine.

    OSX should immediately recognize the card. My system acted a little funky until I did a restart. Menus were bouncing around and keyboard and trackpad weren’t working. I also doubled checked that my ribbons were securely fastened.

    After restarting everything was back the system was back to normally and I was connected to my router.

    Possible Things to Trouble Shoot

    Many people have had wifi issues after upgrading to 10.5.8. Apparently Apple stopped supporting certain cards. Here is a kext from 10.5.7 that should enable the support of your card if it was working in 10.5.7.

    Good luck with the card swap.



« Newer PostsOlder Posts »