[0.14.13] gui direction does not seem to work

Place to get help with not working mods / modding interface.
matjojo
Filter Inserter
Filter Inserter
Posts: 338
Joined: Wed Jun 17, 2015 6:08 pm
Contact:

[0.14.13] gui direction does not seem to work

Post by matjojo »

I'm making a mod, that for the setup-progress needs some gui work, I use a lot of the gui without any problems, but tody I got into a problem that I have not been able to fix for over three hours...

This is my gui-frame:

Code: Select all

gui = playerdata.gui.center.FT_FR_teamsetup.FT_FL_teams_overview
gui.add{type = "frame", name = team.name, caption = team.name, direction = "vertical"}
gui[team.name].add{type = "frame", name = "FT_FR_players_in_team", caption = {"gui.players-in-this-team"}, style = "FT_FR_players_in_team", direction = "vertical"}
code that add's the labels:

Code: Select all

gui.add{type = "label", name = d, caption = d}
where d is a string the the player's name
I took some lines from it to make it readable.
One would expect the "FT_FR_players_in_team" gui-frame to place labels into it with the give direction, vertical. it does this, but only half:
one label in it:
Image
Two labels in it:
Image

it seems to make space for pushing the second one down, but does not actually does that.


anyone any idea?

If you'd want the complete mod, and directions to get in this part, ask, and I'll add them.
Last edited by matjojo on Fri Oct 14, 2016 7:33 pm, edited 1 time in total.
User avatar
prg
Filter Inserter
Filter Inserter
Posts: 947
Joined: Mon Jan 19, 2015 12:39 am
Contact:

Re: [0.14.13] gui direction does not seem to work

Post by prg »

Try putting the labels into a flow.
Automatic Belt (and pipe) Planner—Automate yet another aspect of constructing your factory!
matjojo
Filter Inserter
Filter Inserter
Posts: 338
Joined: Wed Jun 17, 2015 6:08 pm
Contact:

Re: [0.14.13] gui direction does not seem to work

Post by matjojo »

prg wrote:Try putting the labels into a flow.
I made it a bit more clear in OP, it's already in a frame, I just made it look like an "outer_frame_style" which is not visible as frame, only as flow with a caption.

I'd rather not add a flow in the frame, as I should not have to do it, I really should not have to do that.
User avatar
aubergine18
Smart Inserter
Smart Inserter
Posts: 1264
Joined: Fri Jul 22, 2016 8:51 pm
Contact:

Re: [0.14.13] gui direction does not seem to work

Post by aubergine18 »

The GUI is getting reworked in 0.15, but until then you'll probably need to use flows in addition to frames.
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
matjojo
Filter Inserter
Filter Inserter
Posts: 338
Joined: Wed Jun 17, 2015 6:08 pm
Contact:

Re: [0.14.13] gui direction does not seem to work

Post by matjojo »

aubergine18 wrote:The GUI is getting reworked in 0.15, but until then you'll probably need to use flows in addition to frames.

darn, that kinds sucks, I mean I like the rework, but I already spent months on this, I guess it's never bad to get more experience.
Post Reply

Return to “Modding help”