I'm using "now playing (basic)" script after small modification like this
var ft1 = 50, ft2 = 42, ft3 = 30, y1 = 0, y2 = 75, y3 = 150;
//the track info section displays 4 lines of title formatted text. you can customise that here/////////////////////////////////////////////
var line1 = {
text: "", //leave this blank
tf: "$if2(%artist%,No Artist Info)", //enter any title formatting
font: _.gdiFont("Segoe UI", ft1, 1), //font name, size, style. 1 means bold and 0 is normal.
colour: _.RGB(40, 40, 40), //colour
y: y1 //change this value to move text up or down.
}
var line2 = {
text: "",
tf: "$if2(%title%,No Song Info)",
font: _.gdiFont("Segoe UI", ft2, 1),
colour: _.RGB(90, 90, 90),
y: y2
}
var line3 = {
text: "",
tf: "$if([%album% ]['('%date%')'],[%album% ]['('%date%')'],No Album Info)",
font: _.gdiFont("Segoe UI", ft3, 1),
colour: _.RGB(140, 140, 140),
y: y3
}
And, I'm trying to change the font & location of line1, line2, line3 after getting a notification from another panel.
I've put "window.NotifyOthers("width_notify",ww);" within 'function on_size()' in another panel.
So, I inserted the following code to change the font size and location.
function on_notify_data(name, info) {
if(name=="width_notify") {
if(info==1920) {
ft1 = 50, ft2 = 42, ft3 = 30, y1 = 0, y2 = 75, y3 = 150;
window.Repaint();
} else {
ft1 = 30, ft2 = 22, ft3 = 15, y1 = 0, y2 = 40, y3 = 80;
window.Repaint();
}
}
}
But this dosen't work for my purpose. I'm not familiar with the programming language.
So, please give me some hint.