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

TrackInfoMod Alignment

Hi Guys

I'm looking for some help on how to align text in trackinfomod (only just started using it).

Lets say I've currently got this:

Artist: some artist
Title: some title
Album: some album
Comment: some comment

How would I align the above text the following two ways:

1.

Artist:.......some artist
Title:.........some title
Album:......some album
Comment: some comment

2.

......Artist: some artist
........Title: some title
.....Album: some album
Comment: some comment

In the above examples the alignment is slightly off but you get the idea.

Any help would be appreciated.

Thanks

TrackInfoMod Alignment

Reply #1
made more than one for every row

one label (artist) second label (some artist)

simple

TrackInfoMod Alignment

Reply #2
Hi

Thanks for the reply.

But my titleformatting knowledge in general is pretty basic and I have no prior experience with trackinfomod so it wasn't of much help.

Can anyone provide some example code on how to do the above alignments. I'd be able to work off that.

Thanks


TrackInfoMod Alignment

Reply #4
For what it is worth, I suggest splitting the task into two sections. First the labels then the data. You can then draw each of the labels using a textbox with either left or right justification and then draw each of the data using left justification.

For Example 1:
Code: [Select]
// Labels
$alignabs(0,0,40,10,left,)[Artist]:
$alignabs(0,10,40,10,left,)[Title]:
$alignabs(0,20,40,10,left,)[Album]:

// Data
$alignabs(40,0,100,10,left,)%album artist%
$alignabs(40,10,100,10,left,)%title%
$alignabs(40,20,100,10,left,)%album%
For Example 2:
Code: [Select]
// Labels
$alignabs(0,0,40,10,right,)[Artist]:
$alignabs(0,10,40,10,right,)[Title]:
$alignabs(0,20,40,10,right,)[Album]:

// Data
$alignabs(40,0,100,10,left,)%album artist%
$alignabs(40,10,100,10,left,)%title%
$alignabs(40,20,100,10,left,)%album%

TrackInfoMod Alignment

Reply #5
Hi,
I need a little help with an alignment issue: 

Latest foobar 9.5.3, columns ui with one trackInfoMod window.

Please understand that my programming skills are very, very superficial.  I am trying to learn as I really like foobar.

I am trying to export my config file from my desktop to my laptop.  Foobar was originally configured on my desktop at 1600x1200 screen resolution.  When displayed on my laptop which has a max resolution of 1200x800, everything is shifted way to the right.  There is one thing I need help with:

I draw a box, color it, etc:
$drawrect(0,0,1000,0,pencolor-158-35-0 brushcolor-255-255-255 blur-200)
The 1000 value is the new width that was changed from 0 to fit the lower resolution screen.  This worked ok.

My next line of code prepares to center and set fonts for what's coming:
$align(center,middle)$font(,30,,SYSCOL-20)
then I go into if statements checking for tracks, etc.

My problem is that the align function does not center my text into the box I just drew with the drawrect.  It's still shifted to the right, and for the life of me I can't figure out why. I tried alignrel with same results.  What am I doing wrong?

Any help would be highly appreciated!!

TrackInfoMod Alignment

Reply #6
Ok I figured out the above problem.  All I had to do was to use the $alignabs(X,Y,w,h,H,V) function PROPERLY.   

Cheers!