the radio show thing

Talk about today's strip, or anything about the comic in general. You can also talk about any of the characters... but don't expect a response. They're FICTIONAL, you guys... sheesh. :)
User avatar
Mae Dean
Forum Goddess
Forum Goddess
Posts: 4450
Joined: Tue Feb 11, 2003 7:10 pm
Location: San Francisco, CA
Contact:

Post by Mae Dean » Wed Dec 07, 2005 9:13 pm

Excellent! Hopefully either tonight or tomorrow, I'll get the time to add this to the site!

(I assume I'll also need to copy the .js files off of your server, too. :D Quick Q: Do the shows need to be added to that list in order, or can they just be appended to the end as I get them? Also, I noticed some weird code to replace apostrophes - where can I find that info? Just in case I mess up down the line. :) )

dmpotter
Redshirt
Posts: 4057
Joined: Tue Apr 01, 2003 7:10 pm
Location: Massachusetts, US
Contact:

Post by dmpotter » Wed Dec 07, 2005 10:00 pm

[quote="Greg Dean";p="570553"](I assume I'll also need to copy the .js files off of your server, too. :D[/quote]
Yeah, the current files are:

schedule2.js - JavaScript "library" for handling the shows and moving them around
rlradio.js - Current schedule data
schedule2.css - Various CSS rules
Quick Q: Do the shows need to be added to that list in order, or can they just be appended to the end as I get them? Also, I noticed some weird code to replace apostrophes - where can I find that info? Just in case I mess up down the line. :) )
Shows can be added in any order, although if you accidently overlap them, shows at the end will appear on top of shows at the start. Other than that, order doesn't matter in the least.

The apostrophes in the show titles are the "smart quote" style, the “’” type. The ’ character is escaped as "\u2019" in JavaScript.

Since the JavaScript code was used to generate the title images (indirectly, try "javascript:createScriptFu()" on the schedule page, it requires this script which is currently a GIMP 2.0 script), it was needed to use the "smart quote" style quotes. It's really not all that important, though, if you create the title images on your own.

Edit: Oh, and for new shows, it expects to find title images in a directory that can be defined in the schedule2.js file. The file name is "simply" the first 24 characters with spaces replaced by "_" and any non-alphanumeric (or "_") removed.

Simplest method of finding out what it wants would be to use the following as a bookmarklet:

Code: Select all

javascript:n=prompt("Enter show name:");void(prompt("Show title file name is:",n.substring(0,24).replace(/ +/g, "_").replace(/[\W]+/g, "").toLowerCase() + ".png"));
The answer comes up in a "prompt" window to allow you to easily cut-and-paste the name out.

heavybass
Redshirt
Posts: 579
Joined: Fri Feb 14, 2003 11:46 am
Gender: Male

Re: the radio show thing

Post by heavybass » Wed Dec 07, 2005 11:29 pm

Hi can I ask a question about the radio show... now Greg I'm hoping to host a show online cause I haven't got much to do and college I'm doing alright in which means I'm going to try and attempt to make an audition for a show (probably 1-2 hours, 3 if your impressed) mix between music and chat.

Now I do not have much on sound recording except for the default sound recorder in the windows accessories segment... so is there a default tool I should find or am I beggured because I can't connect with mIRC.

You probably would hear this but I have a natural gift of the gab and with the selection of music that is suited to metal and hard rock that I'm going to get because with the playlists from the other dj's but there's no metal show what so ever.

I would like to have some help here, I'm desperate to get on the RL radio crew because not only do I like the comic but I feel that I can give something back to him and sides I'm Welsh so controversey follows me like a scent.

User avatar
Mae Dean
Forum Goddess
Forum Goddess
Posts: 4450
Joined: Tue Feb 11, 2003 7:10 pm
Location: San Francisco, CA
Contact:

Post by Mae Dean » Thu Dec 08, 2005 9:05 am

So, just adding a show in the list on my side won't necessarily add the title of the show unless I do some sort of link to a script?

You'll have to pardon my noobishness. It is absolute.

Posted Thu Dec 08, 2005 3:16 am:

And it's up!

Still need help with making the script work, but it all looks good. :)

dmpotter
Redshirt
Posts: 4057
Joined: Tue Apr 01, 2003 7:10 pm
Location: Massachusetts, US
Contact:

Post by dmpotter » Thu Dec 08, 2005 4:46 pm

Nice, if Firefox doesn't reload the stylesheet, the page looks really screwy. :)

(Some day I should file a bug report with Mozilla that Firefox never seems to check if stylesheets have been updated.)

Currently the titles are images, primarily to make sure that they fit in the boxes instead of hoping that the browser decides that "11px" means 11 pixels high. I could try a variant where it attempts to duplicate the shadow effect using CSS, but you can't do fractional pixels (most browsers round). That would probably solve some of the GIMP-isms, like the weird looking "Y" in "Devinoch’s Soundtrack to Your Life".

However, since the size for the shows is static (81x32 pixel blocks), it's easiest just to pre-draw the titles and make sure they fit. Essentially the titles are just grayscale PNGs with alpha cropped to be as small as possible. The script will then center them automatically.

User avatar
Deacon
Shining Adonis
Posts: 44234
Joined: Wed Jul 30, 2003 3:00 pm
Gender: Male
Location: Lakehills, TX

Post by Deacon » Thu Dec 08, 2005 5:19 pm

heavybass, now you want to get into the action after swearing to leave?

[quote="dmpotter";p="570963"](Some day I should file a bug report with Mozilla that Firefox never seems to check if stylesheets have been updated.)[/quote]
Didn't seem to be a problem for me :|
The follies which a man regrets the most in his life are those which he didn't commit when he had the opportunity. - Helen Rowland, A Guide to Men, 1922

User avatar
Mae Dean
Forum Goddess
Forum Goddess
Posts: 4450
Joined: Tue Feb 11, 2003 7:10 pm
Location: San Francisco, CA
Contact:

Post by Mae Dean » Thu Dec 08, 2005 7:39 pm

I can dig it, DM. I just don't know exactly what I need to do to run the script that MAKES the titles... how do I use it?

dmpotter
Redshirt
Posts: 4057
Joined: Tue Apr 01, 2003 7:10 pm
Location: Massachusetts, US
Contact:

Post by dmpotter » Thu Dec 08, 2005 9:33 pm

You need the GIMP... although the script currently up there was written for 2.0 and they're up to 2.2 now, so I'd have to modify it to make it work in 2.2 (I think).

There's a Windows version of the GIMP, and it works fairly well, although the 2.2 version has this nasty habit of crashing whenever I try and create new images - which is why I haven't upgraded to 2.0 on one computer. (That and 2.2 moved over to the WORST file dialog boxes ever, as an "enhancement" - bleck.)

The simplest way to create them would be just to create the titles in Photoshop or whatever as you have been creating them and then cropping as small as possible and saving as a grayscale PNG. I really should modify the script so that you can specify the filename used for the title image.

User avatar
Mae Dean
Forum Goddess
Forum Goddess
Posts: 4450
Joined: Tue Feb 11, 2003 7:10 pm
Location: San Francisco, CA
Contact:

Post by Mae Dean » Fri Dec 09, 2005 6:42 pm

If we could try the thing where the browser automatically puts the text in, it might be better. Looking at things, a 2-px offset shadow would be fine, really. So we don't have to worry about the fractional pixels. Or, we could set it to 1.6 or something, so that if it does round, it rounds up.

Mostly, I say this because I really have no idea what to name files if I make the titles myself...and more automation is always better in my book. :)

(Though, wouldn't everyone who visited the page in that instance have to have tahoma?)

Also, I thought there was some sort of PHP function that was able to use fonts on the server to output a graphic file. The sigs we use for our WoW guild do something like that. And I have no idea how to make the script work with the GIMP... got the windows version, and it really just confused me.

heavybass
Redshirt
Posts: 579
Joined: Fri Feb 14, 2003 11:46 am
Gender: Male

Post by heavybass » Fri Dec 09, 2005 6:57 pm

[quote="Deacon";p="570991"]heavybass, now you want to get into the action after swearing to leave?

And I'll be staying away... IRC is being a right bitch

User avatar
Mae Dean
Forum Goddess
Forum Goddess
Posts: 4450
Joined: Tue Feb 11, 2003 7:10 pm
Location: San Francisco, CA
Contact:

Post by Mae Dean » Fri Dec 09, 2005 7:06 pm

Figured out the title name - didn't see your bookmarklet thing up there. In any case, automation would rule. :)

User avatar
Lizzegirle
Forum Queen
Posts: 4378
Joined: Tue Feb 11, 2003 8:42 pm
Location: Rocklin
Contact:

Post by Lizzegirle » Fri Dec 09, 2005 8:35 pm

Heavybass, in order to sign on to the show, you need to be on mIRC.
Image

User avatar
JeppZer
Redshirt
Posts: 1734
Joined: Sat Nov 01, 2003 9:03 pm
Gender: Male
Location: Kiruna, Sweden
Contact:

Post by JeppZer » Fri Dec 09, 2005 11:30 pm

IRC! IRC! the m has nothing todo with it! ARGH! *vein pop* :evil:

heavybass
Redshirt
Posts: 579
Joined: Fri Feb 14, 2003 11:46 am
Gender: Male

Post by heavybass » Sun Dec 11, 2005 3:06 pm

[quote="Lizzegirle";p="571626"]Heavybass, in order to sign on to the show, you need to be on mIRC.[/quote]

Fuuuuuck why did Greg FAIL to mention that... right I know what to do now... screw you all I'm off somewhere else on the net.

And I blame him "points to Deacon"

"leaves"

dmpotter
Redshirt
Posts: 4057
Joined: Tue Apr 01, 2003 7:10 pm
Location: Massachusetts, US
Contact:

Post by dmpotter » Sun Dec 11, 2005 11:35 pm

[quote="Greg Dean";p="571564"]Figured out the title name - didn't see your bookmarklet thing up there. In any case, automation would rule. :)[/quote]
It is automated... sorta. I certainly didn't make all those titles by hand. :)

Problem is, it's a script-fu script for the GIMP combined with a "hidden" JavaScript function to actually create the Scheme used to create the images in the GIMP. And I really don't want to explain how to use script-fu and the GIMP enough to install and run the script - especially because I'm not sure it works in the latest version. (Plus I don't quite like how the script-fu script currently runs.)

Filling in the titles should be doable-ish, but it'll look pretty ugly on any computer that doesn't have ClearType enabled. And, yes, it would require the user to have Tahoma installed locally to look "right."

The real problem is that only Mozilla respected the opacity rule on the text for displaying the "LOADING..." bit with a text shadow. IE ignored its own filter rule, and Opera apparently doesn't support "opacity" even though I could have sworn it did. However, even in that case, the text can be colored to look nearly correct in CSS.

If I get time tomorrow I'll throw up a sample version of something like that.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests