Coder Social home page Coder Social logo

beardygridlayout's Introduction

Beardy's Grid Layout Group

This package fixes an issue in the UGUI Grid Layout Group where child elements are not properly aligned after they wrap around.

Before

After

This issue happens because as it wraps around, it uses the width or height of the main axis to determine how much space is required for the overflowing cells, causing the offset to be based on a width of more cells than there are in that row/column.

Known Issues

The original requirement for this was to fix the issue outlined above, however since the Grid Layout Group component supports so many scenarios, the code has issues with certain settings.

  • Start Axis: Horizontal, Start Corner: Upper Right
  • Start Axis: Horizontal, Start Corner: Lower Right
  • Start Axis: Vertical, Start Corner: Lower Left (With certain child alignments)
  • Start Axis: Vertical, Start Corner: Lower Right (With certain child alignments)

If you'd like to try and fix these issues, pull requests are welcome!

Using

For the most part, this should work exactly like the built-in UGUI Grid Layout Group Component.

Installing

Via Package Manager (with git)

In the Package Manager, click the plus in the top left corner and choose 'Add package from git URL' and use [email protected]:mrbeardy/BeardyGridLayout.git in the box.

Via Package Manager (with filesystem)

First download a zip of the repository and unzip it.

Then, in the Package Manager, click the plus in the top left corner and choose 'Add package from disk' and navigate to the folder you unzipped earlier and select the package.json file.

Via .unitypackage

Visit the releases tab and download the latest .unitypackage, then drag that into the project window in Unity.

beardygridlayout's People

Contributors

mrbeardy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.