Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: //PerSecond Playbacktime (Read 4122 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

//PerSecond Playbacktime

Hi.
yea, so i've discovered the "FofR"-config and i think it's awesome. I already customized alot for my needs, but there's one thing i just can't get right. i'm trying to get a playback_time displayed in the main "Now Playing"-window. right under the the cover and standard song infos. it works in the "Song Detail"-window but it seems not to work in the main window..

// * Now Playing Text *
// ==============

// Hide Text if Option 1
$ifequal($getpvar(textnowplay),0,
// Define Text Position using calculated variables
   $alignabs($get(centrew),$get(textvert),$get(imgw),$get(textheight),center,top)
// Check if in Full Screen mode
   $ifequal($getpvar(fullscreen),0,
      $if(%artist%,$font($getpvar(nowplayfont),20,,$getpvar(nowplayfontcol))%artist%)
      $if(%title%,$font($getpvar(nowplayfonttrack),15,,$getpvar(nowplayfontcoltrack))$char(10)%title%)
      $if(%album%,$font($getpvar(nowplayfontalbum),20,,$getpvar(nowplayfontcolalbum))$char(10)%album%)
      $if($and($not(%album%),$not(%title%),$not(%artist%)),$font($getpvar(nowplayfont),12,,255-255-255)$getpvar(notrack))
      $if(%playback_time% / %length%,$font(century gothic,12,,$getpvar(nowplayfontcolalbum))$char(10)

// Per Second
      %playback_time% / %length%)

that's how far i got. it's under the basic song info text, but it's not counting "persecond". and ya, i know there's a gap between "Play" and "Second". but if i close it, the basic song info is gone, and the time is in the right top-left corner.. counting, though...
i'm not a pro at this so, maybe i just did a rookie-mistake, anyway..
but still, please help, someone!!


//PerSecond Playbacktime

Reply #2
cross post? if you mean the post in the other forum, i already asked someone to delete it, i've just mixed up the forums, sorry.
and yea, i posted this question in the fofR-config forum on his page, but there's like nobody on it, so i thought i'd post it in here, too.. is it that bad?

btw. another question which will probably suit better in here:

i'm trying to find a string which allows me to display the folder name of some particular files, without the rest of the path. just the folder they're in. i've got some single tracks, tagged as various artists and they're supposed to be grouped by their parent folder. i mean, i could do that by just write a comment or something and then just display the %comment%-tag, but this ain't the elegant solution and not the effective one, actually..

or, else, just delete this one, too. sorry again.

//PerSecond Playbacktime

Reply #3
i'm trying to find a string which allows me to display the folder name of some particular files, without the rest of the path. just the folder they're in. i've got some single tracks, tagged as various artists and they're supposed to be grouped by their parent folder. i mean, i could do that by just write a comment or something and then just display the %comment%-tag, but this ain't the elegant solution and not the effective one, actually..

http://wiki.hydrogenaudio.org/index.php?ti...irectoryname.25

Quote
that's how far i got. it's under the basic song info text, but it's not counting "persecond". and ya, i know there's a gap between "Play" and "Second". but if i close it, the basic song info is gone, and the time is in the right top-left corner.. counting, though...

You need to align it, probably with $alignabs(), in the // PerSecond section.

Conditions (i.e. $if(),$alignabs() ) are not maintained across the various formating runs.
elevatorladylevitateme

//PerSecond Playbacktime

Reply #4
hmm, i got it like that:

// PerSecond $alignabs($get(centrew),$get(textvert),$get(imgw),$get(textheight),center,top)
      %playback_time% / %length%)

thats the align that was used for the text above from fofR, but still, the PerSecond string does not work.. i bet because the alignabs-string is not working anyway?!
maybe you can just write the right string for me?
as i said, i'm not a pro at this..

and thanks for the directorypath-thing..

//PerSecond Playbacktime

Reply #5
hmm, i got it like that:

// PerSecond $alignabs($get(centrew),$get(textvert),$get(imgw),$get(textheight),center,top)
      %playback_time% / %length%)

thats the align that was used for the text above from fofR, but still, the PerSecond string does not work.. i bet because the alignabs-string is not working anyway?!
maybe you can just write the right string for me?
as i said, i'm not a pro at this..

and thanks for the directorypath-thing..
I hesitate to write code for you because it isn't my config, and I don't know it's innner workings.
But try this:
Code: [Select]
// PerSecond 
$alignabs($get(centrew),$get(textvert),$get(imgw),$get(textheight),center,top)
%playback_time% / %length%)


the // comments out the entire line, so anything on that line will not be read.
elevatorladylevitateme

//PerSecond Playbacktime

Reply #6
actually, i even know that, thah. but yea, thanks for the code. it didn't work though. thanks nonetheless. i guess i'll have to wait till i can figure out the problem..

//PerSecond Playbacktime

Reply #7
Add // Global at the top of the NowPlay configuration file and add
Code: [Select]
// PerSecond
$font($getpvar(nowplayfonttrack),20,,$getpvar(nowplayfontcoltrack))$char(10)%playback_time% / %length%)

to the end of the config and you should get the effect you want.  The problem (I think) is that the variables you have to use to get the correct alignment normally don't carry over from the main section (where the variables are defined) to the // PerSecond section.  Making everything in the section Global fixes it.