cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Submit your abstract to the call for content for Discovery Summit Americas by April 23. Selected abstracts will be presented at Discovery Summit, Oct. 21- 24.
Discovery is online this week, April 16 and 18. Join us for these exciting interactive sessions.
Choose Language Hide Translation Bar
Stas
Level I

Creating tabs in JSL

Hey guys, I'm a very new user and my question is very basic, can you please help me understand how do I create tabs with content? For example instead of textbox X, X tab that will show Y and Z textboxes with it content.

vlistbox(
						textbox("X", <<font color(blue), <<set font size(10), <<set font style("bold")),
						textbox("Y", <<font color(black), <<set font size(10), <<set font style("bold")),
					hlistbox(
								
								
							Button Box("abc", 
							
								Include("")
							),			
							Button Box("def", 
								
								Include("")
							),
													
						),
						textbox("Z", <<font color(black), <<set font size(10), <<set font style("bold")),
					hlistbox(
								
							Button Box("ghi", 
								
								open("")
							),	
							Button Box("jkl", 
								
								Include("")
							),			
							Button Box("mno", 
								
								Include("")
							),
													
						),	
					),

 

 

8 REPLIES 8
pmroz
Super User

Re: Creating tabs in JSL

Something like this?   Be sure to check the scripting index for tab box.

nw = New Window( "Tab Test",
	V List Box(
		tab box(
			"X",
			H List Box(
				Text Box( "Y", <<font color( black ), <<set font size( 10 ), <<set font style( "bold" ) ),
				Button Box( "abc", 
					Include( "" )
				),
				Button Box( "def", 
					Include( "" )
				), 
			),
			"Z",
			H List Box(
				Button Box( "ghi", 
					Open( "" )
				),
				Button Box( "jkl", 
					Include( "" )
				),
				Button Box( "mno", 
					Include( "" )
				),
			), 
		),
	),
);
Stas
Level I

Re: Creating tabs in JSL

It's great, Thank you very much 

Stas
Level I

Re: Creating tabs in JSL

In continue to my question, is there a way to style the tabs or (which is better) change the color/font of the tab text?

ian_jmp
Staff

Re: Creating tabs in JSL

Not answering your question directly but, continuing the example from @pmroz, you can do a right mouse click to bring up the properties of the display:

 

Screenshot 2020-05-21 at 10.50.15.png

 

Screenshot 2020-05-21 at 10.55.42.png

pmroz
Super User

Re: Creating tabs in JSL

Cool Ian - I had no idea you could do that!  Thanks for pointing it out.

ian_jmp
Staff

Re: Creating tabs in JSL

No problem! A nice (JMP 14?) feature that I always thought didn't get enough attention.

Martin
Level V

Re: Creating tabs in JSL

@pmroz what is the purpose of the "V List Box" in this script?

 

Martin

pmroz
Super User

Re: Creating tabs in JSL

I only included it because the original poster had it in their code.  Technically it is not needed for my example.