Man what a great widget. I've only been using the Sirius player, this is like a breath of fresh air. I dont know what the modification policy on these widgets are, but I just did a tiny amount of tweaking to the font size. I updated the size of the top fonts (Channel, Channel Name, Genre) along with the Artist and Title text. If there are any other text size requests, let me know. I am certainly not the author of this amazing widget...they did an awesome job.
First, make a back up of the file MainScreen.js in the Sirius Tuner.widget/Contents folder. This way you can always go back to the way it was if you dont like it with the bigger font.
Open the MainScreen.js file with a text editor (notepad) and replace the entire contents with the below:
Code:
/*
Sirius Tuner Widget
by Tanner Jepsen
Not affiliated with or supported by Sirius Radio Online
Portions Copyright (c) 2005 Jason William. All rights reserved.
Copyright (c) 2005 Tanner Jepsen. All rights reserved.
*/
include("Screen.js");
/**
* The main screen for the Sirius player which will display channel info while
* playing.
*/
function MainScreen(player) {
// reference to the Sirius Tuner
this.player = player;
// set up the screen elements
this.channelDisplay = new Text();
this.genreDisplay = new Text();
this.artistDisplay = new Text();
this.titleDisplay = new Text();
this.albumDisplay = new Text();
this.statusDisplay = new Text();
this.presetBankDisplay = new Text();
// initialize the screen
this.init();
}
// extend the Screen object
MainScreen.prototype = new Screen();
MainScreen.prototype.init = function() {
this.channelDisplay.alignment = "left";
this.channelDisplay.size = 10;
this.channelDisplay.bgColor = "#000000";
this.channelDisplay.bgOpacity = 180;
this.channelDisplay.color = "#FFFFFF";
this.channelDisplay.opacity = 0;
this.channelDisplay.data = "Channel";
this.channelDisplay.window = main;
this.channelDisplay.hOffset = 1;
this.channelDisplay.vOffset = this.channelDisplay.height - 1
this.addSubView(this.channelDisplay);
this.genreDisplay.alignment = "right";
this.genreDisplay.size = 10;
this.genreDisplay.bgColor = "#000000";
this.genreDisplay.bgOpacity = 180;
this.genreDisplay.color = "#FFFFFF";
this.genreDisplay.opacity = 0;
this.genreDisplay.data = "Genre";
this.genreDisplay.window = main;
this.genreDisplay.hOffset = screen.width - 1;
this.genreDisplay.vOffset = this.genreDisplay.height - 1;
this.addSubView(this.genreDisplay);
this.artistDisplay.width = screen.width - 6;
this.artistDisplay.alignment = "left";
this.artistDisplay.size = 16; //12
this.artistDisplay.opacity = 0;
this.artistDisplay.data = "Artist";
this.artistDisplay.scrolling = "autoLeft";
this.artistDisplay.window = main;
this.artistDisplay.hOffset = 3;
this.artistDisplay.vOffset = (screen.height / 3) + 5;
this.addSubView(this.artistDisplay);
this.titleDisplay.width = this.artistDisplay.width;
this.titleDisplay.alignment = "left";
this.titleDisplay.size = 16; //12
this.titleDisplay.opacity = 0;
this.titleDisplay.data = "Title";
this.titleDisplay.scrolling = "autoLeft";
this.titleDisplay.window = main;
this.titleDisplay.hOffset = 3;
this.titleDisplay.vOffset = this.artistDisplay.vOffset + this.artistDisplay.height
this.addSubView(this.titleDisplay);
this.albumDisplay.width = this.titleDisplay.width;
this.albumDisplay.alignment = "left";
this.albumDisplay.size = 10;
this.albumDisplay.opacity = 0;
this.albumDisplay.data = "Title";
this.albumDisplay.scrolling = "autoLeft";
this.albumDisplay.window = main;
this.albumDisplay.hOffset = 3;
this.albumDisplay.vOffset = this.titleDisplay.vOffset + this.titleDisplay.height;
this.addSubView(this.albumDisplay);
this.statusDisplay.width = screen.width - 27;
this.statusDisplay.alignment = "left";
this.statusDisplay.size = 8;
this.statusDisplay.opacity = 0;
this.statusDisplay.data = "Ready";
this.statusDisplay.scrolling = "autoLeft";
this.statusDisplay.window = main;
this.statusDisplay.hOffset = 2;
this.statusDisplay.vOffset = screen.height - 2;
this.addSubView(this.statusDisplay);
this.presetBankDisplay.width = 20;
this.presetBankDisplay.size = 8;
this.presetBankDisplay.style = "bold";
this.presetBankDisplay.opacity = 255;
this.presetBankDisplay.data = preferences.lastActivePresetBank.value;
this.presetBankDisplay.window = main;
this.presetBankDisplay.hOffset = screen.width - 20;
this.presetBankDisplay.vOffset = screen.height - 2;
this.addSubView(this.presetBankDisplay);
this.signalStrength = new Array();
for (var i = 0; i < 3; i++) {
this.signalStrength[i] = new Image();
this.signalStrength[i].src = "Images/signal_tick_" + (i + 1) + ".png";
this.signalStrength[i].vAlign = "bottom";
this.signalStrength[i].window = main;
this.signalStrength[i].opacity = 20;
this.signalStrength[i].hOffset = screen.width - 12 + (i * 3);
this.signalStrength[i].vOffset = screen.height - 2;
this.addSubView(this.signalStrength[i]);
}
}
/**
* Sets a message to appear in the status area of the screen.
*/
MainScreen.prototype.setStatusDisplay = function(text) {
if (this.statusDisplay.data != text) {
if (this.statusDisplay.opacity > 0) {
this.statusDisplay.fade(this.statusDisplay.opacity, 0, 1);
}
this.statusDisplay.data = text;
this.statusDisplay.fade(0, 255, 1);
}
}
MainScreen.prototype.setChannelDisplay = function(ch) {
this.channelDisplay.data = " " + ch.num + " " + ch.name;
this.genreDisplay.data = ch.catname;
this.channelDisplay.width = this.channelDisplay.width + (screen.width - 6)
- (this.channelDisplay.width + this.genreDisplay.width);
this.channelDisplay.opacity = 255;
this.genreDisplay.opacity = 255;
}
MainScreen.prototype.setMainDisplay = function(ch) {
log("Updating main display");
if (ch != null && ch.currentArtist != null) {
this.artistDisplay.data = ch.currentArtist;
this.titleDisplay.data = ch.currentTitle;
this.albumDisplay.data = ""; //ch.currentAlbum;
}
else {
this.artistDisplay.data = ch.name;
this.titleDisplay.data = "Waiting for data...";
this.albumDisplay.data = ""; //ch.currentAlbum;
}
this.artistDisplay.opacity = 255;
this.titleDisplay.opacity = 255;
this.albumDisplay.opacity = 255;
}
MainScreen.prototype.updatePresetBankDisplay = function() {
this.presetBankDisplay.data = this.player.activePresetBank;
}
MainScreen.prototype.updateSignalStrength = function(strength) {
for (var i = 0; i < 3; i++) {
if (strength >= 100 * ((i + 1) / 3)) {
this.signalStrength[i].opacity = 255;
} else if (strength < 100 * (i / 3) || strength == null) {
this.signalStrength[i].opacity = 20;
} else {
var opacity = 255 * ((strength - (100 * (i / 3))) / (100 * (1 / 3)));
if (opacity < 20) {
this.signalStrength[i].opacity = 20;
} else {
this.signalStrength[i].opacity = opacity;
}
}
}
}
MainScreen.prototype.upButtonClicked = function() {
this.player.nextChannel();
}
MainScreen.prototype.downButtonClicked = function() {
this.player.previousChannel();
}
MainScreen.prototype.playButtonClicked = function() {
this.player.play();
}
MainScreen.prototype.updateChannelData = function() {
this.setMainDisplay(this.player.siriusTuner.currentChannel);
}
then simply save, close the widget if its already open, and open it back up.
Please note, I dont take any responsibility for my poor coding. Please make a backup of the original MainScreen.js file in case there is a problem.