Need help with strange issue with screen layers.

If you created a new screenset and want to share it with others then please post it here. You can talk about screens here.

Need help with strange issue with screen layers.

Postby kig23 » Wed Aug 15, 2018 7:19 am

Hi,
i'm working on a new screenset, but i've a strange issue. On the RUN tab (layer 2) i add two sub tabs (layer 21 and layer 22). When i'm in screen edit mode and select the TOOLS tab (layer 5) and save screenset file, on startup, UCCNC opens the TOOLS tab (works like expected), but on the tool tab are also the controls of layer 21. I've checked and all controls of layer 21 are set to layer 21. Am i missing something? Please give some advice to solve the problem. Thanks.
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy

Re: Need help with strange issue with screen layers.

Postby dezsoe » Wed Aug 15, 2018 8:19 am

What is the parent layer of layer 21? If you want to display it only on Run layer, then you have to set the parent to 2.
dezsoe
 
Posts: 2049
Joined: Sun Mar 12, 2017 4:41 pm
Location: Csörög, Hungary

Re: Need help with strange issue with screen layers.

Postby kig23 » Wed Aug 15, 2018 9:30 am

Hi Dezsoe. The parent layer of layer 21 is 2.
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy

Re: Need help with strange issue with screen layers.

Postby dezsoe » Wed Aug 15, 2018 9:58 am

Hi,

In the "//Select the startup layers for the main screen" section do you have an AS3.selectlayer(21); before the AS3.selectlayer(5);?
dezsoe
 
Posts: 2049
Joined: Sun Mar 12, 2017 4:41 pm
Location: Csörög, Hungary

Re: Need help with strange issue with screen layers.

Postby kig23 » Wed Aug 15, 2018 10:14 am

Thanks Dezsoe. The section (select the startup layers for the main screen) is:

AS3.selectlayer(5);
AS3.selectlayer(21);
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy

Re: Need help with strange issue with screen layers.

Postby dezsoe » Wed Aug 15, 2018 10:16 am

That is the problem. Layer 5 is selected and then layer 21 on it. Change the two lines and it should work.
dezsoe
 
Posts: 2049
Joined: Sun Mar 12, 2017 4:41 pm
Location: Csörög, Hungary

Re: Need help with strange issue with screen layers.

Postby kig23 » Wed Aug 15, 2018 11:21 am

Thanks Dezsoe. It's works fine. I thought that UCCNC automatically sets the layer order in the screenset file. Thanks again.
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy

Re: Need help with strange issue with screen layers.

Postby kig23 » Thu Aug 16, 2018 3:27 pm

Hi again. The problem is back. Works if you manualy change the position of the layer in the sceernset file. I saw that the last selected layer (child of layer 1) before saving the screenset file UCCNC puts in bottom of all AS3.selectlayer() in the section (select the startup layers for the main screen). But unfortunately in my case puts the last selected layer after the layer 21. Like i told i have run tab (layer2) and on the run tab i have 2 sub layers (tabs - children of layer 2, with layer numbers 21, 22).
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy

Re: Need help with strange issue with screen layers.

Postby kig23 » Wed Sep 19, 2018 10:00 am

The problem is solved. There is no need to workaround. The problem was in the tab section of the screenset file and not in select startup layers section. Here is a simple example. If you have in between of the tabs ( with parent layer 1 ) other tabs with other parent layers, when you save the screenset file with selected layer 3 at startup on the layer 3 you'll see layer 21 or 22 overlaped. I think that the select startup layers section is related to the tab section.
Code: Select all
//Add tabs to main screen
AS3.Addtab("", "Arial", "center",24, 0,70, 25, 84, 26, 31, 2, 1);
AS3.Addtab("", "Arial", "center",24, 0,480, 419, 130, 26, 33, 21, 2);
AS3.Addtab("", "Arial", "center",24, 0,610, 419, 130, 26, 34, 22, 2);
AS3.Addtab("", "Arial", "center",24, 0,166, 27, 161, 26, 92, 3, 1);

If you put the layer 21 and 22 after all layers with parent layer 1 in the tab section, when you save the screenset file with selected layer 3 at startup you'll see layer 3 and works like expected.
Code: Select all
//Add tabs to main screen
AS3.Addtab("", "Arial", "center",24, 0,70, 25, 84, 26, 31, 2, 1);
AS3.Addtab("", "Arial", "center",24, 0,166, 27, 161, 26, 92, 3, 1);
AS3.Addtab("", "Arial", "center",24, 0,480, 419, 130, 26, 33, 21, 2);
AS3.Addtab("", "Arial", "center",24, 0,610, 419, 130, 26, 34, 22, 2);


Hope this is useful.
kig23
 
Posts: 158
Joined: Sat Mar 31, 2018 6:58 am
Location: Italy


Return to Custom Screensets

Who is online

Users browsing this forum: No registered users and 4 guests