Awesome Icons

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
thims
Posts: 17
Joined: Tue Jun 09, 2015 11:42 pm

Awesome Icons

Post by thims » Tue Oct 27, 2015 9:54 pm

I have stumbled into a free font called Font-Awesome. It is an iconic unicode vector font with 585 icons that are truly superb. Totally scalable with all the standard web icons for Twitter, facebook, Tux, Win etc etc etc.

They are intended for web designers but I use them in LiveCode like so:

set the useUnicode to true
set the textFont of btn "Whatever" to "FontAwesome"
set the unicodeLabel of btn "Whatever" to numToChar(61555) -- 61555=0xf073 from their "cheat sheet"

and voila a perfect little icon (in this case a calendar) in whatever size I need, but that's not all.

use a field and you can import the graphic as an image and eliminate the necessity of including the font with your stack. like so:

set the useUnicode to true
set the textFont of fld "whereTheSymbolIs" to "FontAwesome"
set the unicodetext of fld "whereTheSymbolIs" to numToChar(61555) -- Calendar
import snapshot from field "wheretheSymbolIs"

then just move the image into a storage stack or wherever you store you images and use it as the icon of a button or whatever

Not exactly at you would like it? No problem you can export it with:
export image Calendar9 to file "Calendar9.png" as PNG

and you can edit it in any image editor and then re-import it via the Import as Control from the file menu.

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Awesome Icons

Post by Simon » Wed Oct 28, 2015 1:26 am

Hi thims,
In LC8 fontawesome is included :)

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

thims
Posts: 17
Joined: Tue Jun 09, 2015 11:42 pm

Re: Awesome Icons

Post by thims » Wed Oct 28, 2015 1:41 am

What "awesome" news. Sorry ... I couldn't resist.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: Awesome Icons

Post by richmond62 » Wed Oct 28, 2015 9:07 pm

So, where does one get this font?

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: Awesome Icons

Post by richmond62 » Wed Oct 28, 2015 9:09 pm


Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Awesome Icons

Post by Klaus » Wed Oct 28, 2015 10:37 pm

Simon wrote:Hi thims,
In LC8 fontawesome is included :)

Simon
Yep, and it looks fantastic!

Post Reply