You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

servaas

Intermediate

  • "servaas" started this thread

Posts: 204

Location: Belgium

  • Send private message

1

Saturday, March 29th 2014, 2:52pm

floornumbers..



Hello,

I want the floor numbers 0 and 1 aligned at the left side on my window but when I do so, the numbers switch position...


I my code I changed

Source code

1
set(plugin[get(floor_btn)].align,righttop);
into

Source code

1
set(plugin[get(floor_btn)].align,lefttop);


why do the numbers change position... ? *confused*

I use an image like
(I can't put exact image as it's white text on an transparant background)

Does anyone has an idea ?
Thanks a lot !

Tuur

Sage

Posts: 3,154

Location: Netherlands

Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Send private message

2

Saturday, March 29th 2014, 6:40pm

Your question is completely unclear.
Please get us a link, code and a clear description etc..
Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

servaas

Intermediate

  • "servaas" started this thread

Posts: 204

Location: Belgium

  • Send private message

3

Monday, March 31st 2014, 3:33pm

I admit I was in a hurry :-)
Sorry for that :-)

Here is the project:
http://immo-virtueel.be/krpano/

Here you can find the code.
http://immo-virtueel.be/krpano/xml/map.xml

At this moment the floor numbers (0 1) are aligned to the right with this code :
line 110

Source code

1
set(plugin[get(floor_btn)].align,righttop);


When I align the floor numbers to the left, the floor numbers switch place to 1 0.
http://immo-virtueel.be/krpano/index2.html

Source code

1
set(plugin[get(floor_btn)].align,lefttop);



How can I change this ?

thanks

Alexey Tkachenko

Professional

Posts: 742

Location: Sevastopol, Crimea, Russian Federation

Occupation: Interpreting, Building virtual tours

  • Send private message

4

Monday, March 31st 2014, 9:56pm

Hi! quite a complicated code and structure... It might require a good tracing of all values to find the exact spot of the code where calculations go wrong.

I would start here:

Source code

1
2
3
4
5
<!-- put the buttons under eachother -->
			copy(plugin[get(floor_btn)].x, floor_menu_xoffset);
			add(floor_menu_xoffset, get(menu.floor.height));
			add(floor_menu_xoffset, menu.floor.padding);
			copy(plugin[get(floor_btn)].y, menu.yoffset);


first and quick try: replace "add" with "sub" and see how this will affect positions of the buttons. I mean this:


Source code

1
2
3
4
5
<!-- put the buttons under eachother -->
			copy(plugin[get(floor_btn)].x, floor_menu_xoffset);
sub(floor_menu_xoffset, get(menu.floor.height));
sub(floor_menu_xoffset, menu.floor.padding);
			copy(plugin[get(floor_btn)].y, menu.yoffset);



Obviously, there's a complicated queue of copy-paste of parameters from the "menu" array in your "interface.xml" so simple change of "align" might require also changes in other "links" of code.
Regards,

Alexey

servaas

Intermediate

  • "servaas" started this thread

Posts: 204

Location: Belgium

  • Send private message

5

Tuesday, April 1st 2014, 9:54am

Hello Alexey,

I admit that It's all a bit copy and paste :-)

Your code does a strange thing as well, but I'll check out my other codes again.
I'm far from an expert but I'll do my best :-)


Thanks for the reaction.
Servaas

This post has been edited 1 times, last edit by "servaas" (Apr 1st 2014, 10:24am)


servaas

Intermediate

  • "servaas" started this thread

Posts: 204

Location: Belgium

  • Send private message

6

Tuesday, April 1st 2014, 10:25am

Sorry Alexey !
The code you give does work perfect !

Thanks a lot !

Servaas