Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed width component #19

Closed
eranimo opened this issue Nov 11, 2014 · 2 comments
Closed

Fixed width component #19

eranimo opened this issue Nov 11, 2014 · 2 comments

Comments

@eranimo
Copy link

eranimo commented Nov 11, 2014

Currently I'm trying something where if the component is resized outside a certain size, it will go back to the previous size. This however seems a bit buggy, and it would be nice if we could specify a width or height in absolute pixel values and prevent it from being resized.

Also, it seems when you regroup components without a specified width that are next to another component with a specified width, that specified width is changed.

@deepstreamIO
Copy link
Contributor

Hi eranimo,

my apologies upfront: this will be an unsatisfying answer.
GoldenLayout doesn't have a concept of an absolute width, in fact, everything in GoldenLayout is relative. This is a fundamental aspect of the "docker" layout approach, as opposed to, e.g. grid based layouts. Everything being relative means that at any moment the available space is used as efficiently as possible and there won't be any gaps. Mixing fixed sized and dynamically sized components will introduce unsolvable logical problems (what if I move my fixed width 200 component into a row that's 500 wide, but already has a fixed width 400 component in it.)

Everything being completely resizeable off course brings additional UX challenges (if you're using outlook, notice in how many different ways your inbox list reformats itself during resizing).

If having fixed sized components with sizes that are multiples of each other is a fundamental requirement of your app, you might want to have a look at Gridster. Personally though I believe that a dynamic layout that adjusts to screen sizes and ratios and makes the best use of all available space is the best possible approach.

@PragmaticEd
Copy link

@deepstreamIO Just letting you know, that link (http://gridster.net/) is dead..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants