Skip to content

Add examples/gt_grid.pl as a demo of the grid geometry manager#140

Merged
dk merged 1 commit intodk:masterfrom
HaraldJoerg:grid_example
Feb 16, 2025
Merged

Add examples/gt_grid.pl as a demo of the grid geometry manager#140
dk merged 1 commit intodk:masterfrom
HaraldJoerg:grid_example

Conversation

@HaraldJoerg
Copy link
Contributor

This is an example of the grid geometry manager, demonstrating rowspan / colspan and cell padding.
I noticed two things:

  • There is no padx / pady padding to the right of the rightmost column nor above the topmost row. A comment in grid.c suggests that half of the padding should appear on either side, but as far as I understand the C code, padLeft and padX have the same value, leaving nothing left for the other side.
  • The documentation of the ipadx option says "The amount must be a valid screen distance, such as 2 or '.5c'." but it does not process units like .5c . Since this is documented only for ipadx I guess this is a unwanted documentation inheritance from Tk rather than a missing feature of Prima.

A Screenshot:
prima_grid_example

@dk dk merged commit 0980265 into dk:master Feb 16, 2025
2 checks passed
dk added a commit that referenced this pull request Feb 18, 2025
@dk
Copy link
Owner

dk commented Feb 18, 2025

Hello Harald,

I think I've got the padx/pady fixed - do they look ok now?

/dk

@HaraldJoerg
Copy link
Contributor Author

Hello Dmitry,
The spacing is now as documented, thanks!

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

Successfully merging this pull request may close these issues.

2 participants