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: foo_ui_panels (Read 1317343 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

foo_ui_panels

Reply #675
This may have been answered before, but I can't find it and am unable to figure it out... Whenever there is no track playing in Foobar (with Panels_UI as the interface), the Title Bar just show a question mark (?). 

Is there anyway to change that to either say Foobar2000 (like the default UI and columns UI) or even better a way to customize it.

Thanks!

foo_ui_panels

Reply #676
The question mark is displayed when you have told foobar to display a variable (let us use %tracknumber% for an example) however there is no data available for that variable. You can compensate for this by telling foobar to only display the variable if there is data available like this:
[%tracknumber%]
or this:
$if2(%tracknumber%,)
Or if you would only like to display data when a track is playing like this:
$if(%isplaying%,
%tracknumber%
,)

foo_ui_panels

Reply #677
Does anyone know why, ever since switching to Panels UI, my drag'n'dropped playlist items always move to the bottom of the playlist? In ColumnsUI, there was an option to have dropped items insert wherever you dropped them. That option, while still set the way it was, obviously doesn't function since i'm using Panels UI. Thanks for any help you can provide


Quoting this for the next page i hopes someone has some idea what I'm doing wrong

foo_ui_panels

Reply #678
The question mark is displayed when you have told foobar to display a variable (let us use %tracknumber% for an example) however there is no data available for that variable. You can compensate for this by telling foobar to only display the variable if there is data available like this:
[%tracknumber%]
or this:
$if2(%tracknumber%,)
Or if you would only like to display data when a track is playing like this:
$if(%isplaying%,
%tracknumber%
,)


I did find it a tad strange that titlebar behaves like Track Display in Mode: Now Playing.  I got over it.  More interestingly,  $extra(foobar2000_version) does not work on the titlebar.  It displays [UNKNOWN FUNCTION].  It looks exactly as it should in the preview, so I believe this is a Panels UI issue.


foo_ui_panels

Reply #680
terrestrial, I know you're inundated with feature requests, but I have to add another of my own. I thought of something that may be quite useful. Through the configuration window or through whatever means you see fit, include the possibility of viewing a "debugging" window that shows a tabular list of all the current variables in use ($puts and $pvars) as well as their real-time values. Perhaps the variable values can even be manipulated or deleted entirely via this window for further debugging. Just a thought.

foo_ui_panels

Reply #681
using v.0.8.1

just updated, are tagz not working in this version for the main window title, tray icon, etc.?

for example, for the main window title, i had

Code: [Select]
%album artist%
-
%title%


and got

?-?

then i put the tagz in [ ]

Code: [Select]
[%album artist%]
-
[%title%]


and got

-

should an extension even alter the main window title, tray icon menu, etc.?
[/font]

foo_ui_panels

Reply #682
gregory: tags appear to be working fine for me and what you have posted is the expected output for the code. Maybe you are looking for something along the lines of this:
Code: [Select]
$if2(
[%album artist% - ][%title%]
,
foobar2000
)


btw foo_ui_panels, although it does require columnsui, is named and developed as a UI not simply a UIE. so I do believe it is free to muck about with the user interface quite a bit more than a typical extension.

foo_ui_panels

Reply #683
terrestrial, I know you're inundated with feature requests, but I have to add another of my own. I thought of something that may be quite useful. Through the configuration window or through whatever means you see fit, include the possibility of viewing a "debugging" window that shows a tabular list of all the current variables in use ($puts and $pvars) as well as their real-time values. Perhaps the variable values can even be manipulated or deleted entirely via this window for further debugging. Just a thought.


You're referring to a 'Watch Window'. Guess it could be useful for some stuff, But definitely not the easiest thing to implement, Maybe going even a bit out of place with a scripting language.

foo_ui_panels

Reply #684
damn, I still don't get how to use the windowsize option on buttons.  Can anyone care to explain how to use as if I was really really dumb?

foo_ui_panels

Reply #685
@gregory

Adding to what Yotsuya said, the PanelsUI scripting for the main window title does not have a default for a not-playing state.  So you have to define it, either as Yotsuya posted, or using $if(%isplaying%,....).

I've also noticed that you must restart foobar to see the changes you've made correctly.

foo_ui_panels

Reply #686
$if(%trackinfo_notrack%,,)
Is probably more useful considering it stays true during a paused state.
elevatorladylevitateme


foo_ui_panels

Reply #688
are we still talking about the window title?!?
never mind me then.

I guess I assumed that this being the panelsUI thread and all, this was about panelsUI.
silly me.


in that case,
@greg-baby
should an extension even alter the main window title, tray icon menu, etc.?
You can hide the titlebar and create a pseudo-titlebar of your own. see my config as an example of this

PanelsUI (I assume in great confidence) will always be dependent on ColumnsUI for generating panels, since the different panels themselves are written for ColumnsUI. So that considered, it makes sense to let Columns do the things it already does perfectly well, like take care of all those little formating strings.
elevatorladylevitateme

foo_ui_panels

Reply #689
Is there any way to clear old PVAR values? I've changed the names to a few of mine and the old ones still show up in the pui; deleting them in notepad results in a corrupt file.


no, not yet. there will eventually be a way to delete pvars though. and editing the .pui files in notepad is almost always going to corrupt the file

I have been trying to put a background image on my foobar. What I want is to keep the aspect ratio of the image, but I don't want the size to adjust with the smallest dimension (ie I don't want black parts on each side of the image).
I have been trying to make it by myself, but this turns out to be really difficult (impossible?) as the mathematical functions I know only use integers.
Anyone knows how to do that? If it is not possible, terrestrial, could you add it as an option for $imageabs2?

Thanks for your help!


do you know the dimensions of the image you want resized? if so, then you would just set one side to what you want, and the other to a large number.


I seem to have a problem with PerTrack and PerSecond option, with version 0.8.1

This is my code, directly in the main panel configuration:
Code: [Select]
// Background
$drawrect(,,,,brushcolor-255-255-255 pencolor-null)

// PerSecond
$panel(NowPlaying,Track Display,10,10,650,500,)

With this code I have [UNKNOWN FUNCTION] displayed in top left corner, it's the same if I use // PerSecond instead of // PerTrack.
If I remove // PerTrack, I only see the background and I don't see any error message (normal behavior).
If I remove both // Background and // PerTrack, everything seems to be fine.

Am I doing something wrong? Am I missing something?

EDIT: I have the same problem in Track Display panels
EDIT2: If I remove // Background and keep // PerTrack, I don't have the error message


check your user / layout globals.

version 0.8.1 regression
I believe with the previous version, (although I've been wrong before) size and position of the window was stored in the .pui; this doesn't seem to be the case with 0.8.1

(and I was really needing this feature, unless, you know, position and/or maximization were made changeable via scripting  )


nope, none of the previous versions stored the window position in the .pui (although it might be a good idea for the future).


I'm in shock. I changed one PVAR on my layout and my entire pui file got wiped out. A weeks worth of coding... gone. 

I had just turned off shadow copy too because of slow copy times.


backup the .puis often and if you can reproduce it, let me know.

nope.
im using the default setpoint drivers, which i used the registry hack to work with foobar.
the keys work perfectly in every other ui, its just panels 


you might need to change the target of the key presses. panels ui uses different a window / class id than the default (or columns) ui.

terrestrial, I know you're inundated with feature requests, but I have to add another of my own. I thought of something that may be quite useful. Through the configuration window or through whatever means you see fit, include the possibility of viewing a "debugging" window that shows a tabular list of all the current variables in use ($puts and $pvars) as well as their real-time values. Perhaps the variable values can even be manipulated or deleted entirely via this window for further debugging. Just a thought.


there will be a way to delete pvars (maybe it will display values too, not sure yet). you can already do a real-time watch for pvars using a regular track display and $getpvar (but you will have to know all the variable names).


PanelsUI (I assume in great confidence) will always be dependent on ColumnsUI for generating panels, since the different panels themselves are written for ColumnsUI. So that considered, it makes sense to let Columns do the things it already does perfectly well, like take care of all those little formating strings.


actually, no it doesn't require ColumnsUI (although the default layout uses panels from ColumnsUI, like the menu and seekbars).

foo_ui_panels

Reply #690
I have been trying to put a background image on my foobar. What I want is to keep the aspect ratio of the image, but I don't want the size to adjust with the smallest dimension (ie I don't want black parts on each side of the image).
I have been trying to make it by myself, but this turns out to be really difficult (impossible?) as the mathematical functions I know only use integers.
Anyone knows how to do that? If it is not possible, terrestrial, could you add it as an option for $imageabs2?

Thanks for your help!

First, you'll have to know the aspect ratio of the image you want to use, because AFAIK, foobar cannot retrieve this information from an image file.  For this example I'll assume it's a standard 4x3 ratio and you want to keep the upper left corner of the image at the 0,0 coordinate of the panel.

Code: [Select]
$ifgreater(%_width%,$eval(4*%_height%/3),
$puts(bg,%_width%)
,
$puts(bg,$eval(4*%_height%/3)
)
$imageabs2($get(bg),$get(bg),0,0,%_width%,%_height%,0,0,'path_to_image',)


I think that should work.  You may want to add an arbitrary number of pixels to the dimension (like 5) to compensate for rounding and avoid any small borders.

foo_ui_panels

Reply #691

I seem to have a problem with PerTrack and PerSecond option, with version 0.8.1

This is my code, directly in the main panel configuration:
Code: [Select]
// Background
$drawrect(,,,,brushcolor-255-255-255 pencolor-null)

// PerSecond
$panel(NowPlaying,Track Display,10,10,650,500,)

With this code I have [UNKNOWN FUNCTION] displayed in top left corner, it's the same if I use // PerSecond instead of // PerTrack.
If I remove // PerTrack, I only see the background and I don't see any error message (normal behavior).
If I remove both // Background and // PerTrack, everything seems to be fine.

Am I doing something wrong? Am I missing something?

EDIT: I have the same problem in Track Display panels
EDIT2: If I remove // Background and keep // PerTrack, I don't have the error message


check your user / layout globals.

Correct! There was a mistake in USer Globals, I noticed it a few minutes ago. Thanks for the reply anyway ;-)


I have been trying to put a background image on my foobar. What I want is to keep the aspect ratio of the image, but I don't want the size to adjust with the smallest dimension (ie I don't want black parts on each side of the image).
I have been trying to make it by myself, but this turns out to be really difficult (impossible?) as the mathematical functions I know only use integers.
Anyone knows how to do that? If it is not possible, terrestrial, could you add it as an option for $imageabs2?

Thanks for your help!

First, you'll have to know the aspect ratio of the image you want to use, because AFAIK, foobar cannot retrieve this information from an image file.  For this example I'll assume it's a standard 4x3 ratio and you want to keep the upper left corner of the image at the 0,0 coordinate of the panel.

Code: [Select]
$ifgreater(%_width%,$eval(4*%_height%/3),
$puts(bg,%_width%)
,
$puts(bg,$eval(4*%_height%/3)
)
$imageabs2($get(bg),$get(bg),0,0,%_width%,%_height%,0,0,'path_to_image',)


I think that should work.  You may want to add an arbitrary number of pixels to the dimension (like 5) to compensate for rounding and avoid any small borders.

I've been trying to do something like that, but I have lots of problems with rounded values and finding the dimension to use as basis. Everything gets messed up quickly if I play with the aspect ratio of foobar.
My code is on another computer, but I'll paste it later. Maybe you'll find something.

 

foo_ui_panels

Reply #692
Well the code I posted above should work for any background image that is a 4x3 aspect ratio, regardless of the size/ratio of your foobar panel.  That's why the $get(bg) variable is based on the panel width and height, so it can change along with it.  If you change bg images to something else, modify the ratio in the code and it should still work.

I haven't tried it, but I would like to know if it does what you want it to.

foo_ui_panels

Reply #693
Don't know if this has been answered before but is it possible to put text on top of glass because it looks washed out behind the glass.

foo_ui_panels

Reply #694
Well the code I posted above should work for any background image that is a 4x3 aspect ratio, regardless of the size/ratio of your foobar panel.  That's why the $get(bg) variable is based on the panel width and height, so it can change along with it.  If you change bg images to something else, modify the ratio in the code and it should still work.

I haven't tried it, but I would like to know if it does what you want it to.

It doesn't seem to work :-(

But I have found a solution

Code: [Select]
$ifgreater(
    $eval(%_width%*10),$eval(%_height%*16),
    $imageabs2(%_width%,$eval(%_width%*10/16),0,0,,,0,0,skins/skin2/bg.png,),
    $imageabs2($eval(%_height%*16/10),%_height%,0,0,,,0,0,skins/skin2/bg.png,)
)


The main problem I had came from my previous comparison that generated non-integer results
Code: [Select]
$eval(16/10),$eval(%_width%/%_height%)


As you said earlier, now I just need to add some pixels to remove black borders.

foo_ui_panels

Reply #695
Aww geez, I went braindead.  I missed a ) and I forgot that you can't stretch an image greater than it's original size if you don't use 'nokeepaspect'.  So here's the corrections edited for your 16x10 ratio -

Code: [Select]
$ifgreater(%_width%,$eval(16*%_height%/10),
$puts(bgW,%_width%)
$puts(bgH,$eval(10*%_width%/16))
,
$puts(bgW,$eval(16*%_height%/10))
$puts(bgH,%_height%)
)
$imageabs2($get(bgW),$get(bgH),0,0,%_width%,%_height%,0,0,'path_to_image',nokeepaspect)

foo_ui_panels

Reply #696
Aww geez, I went braindead.  I missed a ) and I forgot that you can't stretch an image greater than it's original size if you don't use 'nokeepaspect'.  So here's the corrections edited for your 16x10 ratio -
(...)

That's more or less the same code as mine so we agree! Thanks for your help 

foo_ui_panels

Reply #697
Sorry for duplicating the question. Can SCPL make subgroups (that is. can it group particular tracks inside album-groups)?

foo_ui_panels

Reply #698
not really.

You could do something like this though:


based on %track% and %totaltracks%
elevatorladylevitateme

foo_ui_panels

Reply #699
Using right mouse button to drag files to other apps/folders doesn't work in panels_ui.  Would be a real nice feature.