Skip to main content

Topic: WSH Panel Mod script discussion/help (Read 845422 times) previous topic - next topic

0 Members and 2 Guests are viewing this topic.
  • foo_csx
  • [*]
WSH Panel Mod script discussion/help
Reply #2850
Hey is this a known bug, where .FillGradRect() focus is off by one pixel on certain positions with certain heights?

Code: [Select]
var ww = 0, wh = 0;

function on_size() {
   ww = window.Width;
   wh = window.Height;
}

a = 0xfff00000;
b = 0xff000000;
function on_paint(gr) {
   gr.FillSolidRect(0, 0, ww, wh, 0xff666666);
   for(var j = 0; j < 50; j++)
       for(var i = 0; i < 100; i++)
           gr.FillGradRect(1 + i + j, j + 1, 1, 100 - i - 10, 90, a, b);
   gr.FillGradRect(60, 60, 50, 51, 90, a, b);
}
shouldn't result in this:



or am I missing something?

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2851
it definitely looks like a bug. just that square on its own with the odd number height illustrates that. as the component is no longer developed, you'll probably have to find a workaround for this yourself.

  • foo_csx
  • [*]
WSH Panel Mod script discussion/help
Reply #2852
Setting the angle a bit offset seems to work out okay I guess. For now probably better than digging through the whole sourcode.

  • mire777
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2853
Marc. I put a modified version of your script here: http://mire777.deviantart.com/art/WSH-Biog...C2000-419126433
,especially for xch4nge skin. Is this ok? I hope you do not mind?
If this is a problem, i will delete file.. I ask for your permission?
I wanted to help people who use this skin, because default script wont work..

  • ehrgeiz
  • [*]
WSH Panel Mod script discussion/help
Reply #2854
hey marc,
i ran into a problem using your "now playing script": it doesn't download any artist pictures any more.
console says "Now Playing: HTTP error: 0 "
if there are existing pictures it works fine, also fetching biography works, just downloading pictures wont.
i replaced all files and scripts with the newest version using foobar2000 v1.2.6 (edit: updated to 1.2.9)
do you have any advice how to find out whats causing the problem?

thx a lot

edit: thank you for the quick answer although you told someone else already a few pages earlier (i blame it on the shitty search function ;P)
  • Last Edit: 16 December, 2013, 03:31:07 PM by ehrgeiz

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2855
this happens if you use IE to browse any localised version of the last.fm website (not the english one). hold shift and right click the panel. edit the value of images_domain to whichever last.fm site you use like http://www.lastfm.de, http://www.lastfm.ru etc....

edit: i've updated the script and put a "Help" dialog in a more prominent place with an explanation of recent changes:



right click panel>Update script.
  • Last Edit: 16 December, 2013, 03:41:37 PM by marc2003

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2856
i just realised i forgot to bump the version number on the last update meaning the Update script feature would not work. it's fixed now. 
  • Last Edit: 16 December, 2013, 08:17:43 PM by marc2003

  • redsky
  • [*]
WSH Panel Mod script discussion/help
Reply #2857
Hi marc,

Was hoping you could help, I'm running Br33t's DUiTunes skin using WSH Panel Mod 1.5.6 and I'm seeing:

Code: [Select]
Error: WSH Panel Mod (DUiTunes Playlist Viewer v1.0.0 by Br3tt aka Falstaff >> http://br3tt.deviantart.com): Microsoft JScript runtime error:
Invalid procedure call or argument
File: C:\foobar2000 1.2.9_3\wsh_br3tt\js\WSHplaylist.js
Ln: 2186, Col: 17


Not sure if this is related to the plugin or Playlist Viewer (it happens when I switch to the Playlist Viewer) but was hoping you could point me in the right direction.

Many thanks!

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2858
i can't help with that. i generally provide help for scripts i make or i can help people stuck with their own simpler scripts. i'm not looking at thousands of lines of code i didn't make....  just like you wouldn't expect anyone else to fix a problem with my scripts.

falstaff will probably read this at some point so you should wait for his answer or you can post on his deviantart page.

WSH Panel Mod script discussion/help
Reply #2859
Hello Marc2003
I appreciate your works to customize Foobar2000 very much
I look at your Rating panel (separate panel using WSH panel mod) but the download links are outdated.
Could you provide me the updated link since I really need a separated rating panel to rate my current playing song quickly rather than browse my whole library.

THANK YOU VERY VERY MUCH!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

WSH Panel Mod script discussion/help
Reply #2860
here's another script for DUI. it's a ratings panel that displays the current rating and of course lets you set it. it works with the official playback statistics component. it has the same context menu options as the "buttons" panel above to set the background colour.

when foobar is playing it sticks to now playing. and when playback is stopped, it follows the cursor.

just copy/paste this code into a new panel and download these images and extract them to your foobar folder.

(credit to NEMO7538 for providing the original rating code)

script: http://javascript.pastebin.com/f5450d71a
images: http://cid-649d3bfeaf541fbb.skydrive.live....uide/rating.zip
screenshot: http://k5sbdw.blu.livefilestore.com/y1pQER...-BTE/rating.png


This is the panel I cannot download

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2861
https://dl.dropboxusercontent.com/u/22801321/wsh/samples.zip

the script you want is named rating.txt and make sure to check the readme as well.

  • mrlex
  • [*]
WSH Panel Mod script discussion/help
Reply #2862
Hi Marc, I have been using your scripts for over a year now and the are all amazing!
I logged back on today and grabbed your most up to date versions and have updated my config

Since updating though I seem to get errors. Whenever I right click a panel the component crashes due to a script error.

This seems to be the case for most of the scripts I use (Bio, Similar Artists, AllMusic Review).
I made sure I had Safe mode unticked

Do you have any ideas what the issue might be?

Thanks again!

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2863
if it happens when right clicking, i expect it's because your WSH panel mod component is out of date. my latest scripts require v1.5.0 or above (current version is 1.5.6 available here.)

  • mrlex
  • [*]
WSH Panel Mod script discussion/help
Reply #2864
Genius! Thanks so much

For some reason I never even though to check this (pretty stupid of me)

  • foomark
  • [*][*]
WSH Panel Mod script discussion/help
Reply #2865
I'm using this WSH playlist (Link) and until today i had no problem.
Yesterday i installed the new version od foobar2000 (1.3) and now the playlist crash at startup, it give me a run-time error:

'oList' undefinied
File: <main>
Ln: 349, Col: 9
<source text only available at compile time>

Any idea on how to solve it?


  • foomark
  • [*][*]
WSH Panel Mod script discussion/help
Reply #2866
I'm using this WSH playlist (Link) and until today i had no problem.
Yesterday i installed the new version od foobar2000 (1.3) and now the playlist crash at startup, it give me a run-time error:

'oList' undefinied
File: <main>
Ln: 349, Col: 9
<source text only available at compile time>

Any idea on how to solve it?


Auto quote

Solved, sorry for the stipid question.

WSH Panel Mod script discussion/help
Reply #2867
I don't know if this is a stupid question, but how can you set a (any) property of an item in a playlist?

I'm trying to create a script that compares the active playlist to a "Favorites" playlist, if there are matching items... then... .. . ?

Right now I'm just using nested for() loops... and it can find items, and I can copy/add/remove them from a playlist, but I would rather keep them in-place, and just change the background color, or change any sort of tag at all.

tl;dr... is there a .Item(i).tag("x") = "y" .. sort of possibility?

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2868
you can use UpdateFileInfoSimple to update the tags. presumably you're looping through playlist items something like this...

Code: [Select]
var items = plman.GetPlaylistItems(plman.ActivePlaylist);
for (i = 0; i < items.count; i++) {
    //this code would update every file but you'll have if statements or whatever...
    items.item(i).UpdateFileInfoSimple("TAG", "VALUE");
}

WSH Panel Mod script discussion/help
Reply #2869
Thank you... I was already half-way through coding my own playlist. Being able to make use of the existing/default one is much easier.

And yes, simplified: for each Favorite {find in CurrentList { do stuff;break; }}... since one of the playlists is always at least 1700 songs... it's not particularly speedy, but it makes tracking favorites much easier to reduce duplicates, or just find them in other playlists.

WSH Panel Mod script discussion/help
Reply #2870
Found a bug/error/freeze... this thread is too long to search, and a quick web search didn't result in anything, might be a known issue.

Code: [Select]
        var x = 100;
        var y = 100;
        while(x--){
            while(y--){
                fb.trace(y);
            }
        }


That while will cause WSH/FB to freeze... when it shouldn't. It doesn't completely freeze Foobar instantly... just the UI... if a song is playing it will continue until the end, but not the next track.

A single while(--) loop works well and is slightly quicker than comparable for(--/++) loop... but nesting them crashes... the second loop seems to go past 0... 5, 4, 3, 2, 1, -2...etc... it's strange.

JScript, Windows 8, Foobar 1.3.1 B1, WSH 1.5.6

It's not a CPU limit/freeze either... it's only using about 40 to 70% of one core (i5 3570K @ 4.5GHz - completely stable 24/7 overclock).

For anyone interested, I went with the custom playlist anyways... it's the small one at middle bottom, those 3 auto-hide.
  • Last Edit: 06 January, 2014, 10:34:37 AM by Vectronic

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2871
i'd expect the script to hang because you're not telling it when to stop. i tried the code in a browser using console.log and that also hangs.

  • blaxima
  • [*][*][*]
WSH Panel Mod script discussion/help
Reply #2872
Hi marc,

I've got another question for ya mate.

What would be the path be to get the bio and reviews saved to the corresponding playing songs folder? Right now I have an "Image" folder created by the bio panel that places an album.jpg and artist.jpg and I think I would prefer files to be placed within the albums and genre media folders rather than inside the foobar install. For example the artist  path is      $replace(%path%,%filename_ext%,Images\%artist%)    which I would assume isn't the same for the WSH panel, or am I wrong?

Cheers

  • marc2003
  • [*][*][*][*][*]
WSH Panel Mod script discussion/help
Reply #2873
unless you had all tracks by the same artist in the same folder, it would break my scripts.

  • blaxima
  • [*][*][*]
WSH Panel Mod script discussion/help
Reply #2874
All the tracks in some folders are;

Structure is like this
Genre\Artist\2014 - Album\01 - track, 02 - track, etc..

but I do have some random songs in just the genre folder so I guess that's were I would run into problems

thanks for the quick response