Separation between columns of a GridView

New to Gambas? Post your questions here. No question is too silly or too simple.
Post Reply
User avatar
gambafeliz
Posts: 139
Joined: Friday 2nd September 2022 7:50pm
Location: I live in the same city as Picasso

Separation between columns of a GridView

Post by gambafeliz »

I have a GridView where the width of the columns is set to automatic (Width=-1) but I have a problem.

Example, visual:
Column1 | Column2
09/06/2022 10:0009/06/2022

Is it possible, having the width set to automatic, to put a separation between the columns?

how do i do it?
For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
vuott
Posts: 262
Joined: Wednesday 5th April 2017 6:07pm
Location: European Union

Re: Separation between columns of a GridView

Post by vuott »

gambafeliz wrote: Thursday 8th September 2022 12:11pm having the width set to automatic, to put a separation between the columns?
Excuse me, can you explain better?
Europaeus sum !

Amare memorentes atque deflentes ad mortem silenter labimur.
User avatar
gambafeliz
Posts: 139
Joined: Friday 2nd September 2022 7:50pm
Location: I live in the same city as Picasso

Re: Separation between columns of a GridView

Post by gambafeliz »

Hello, Vuott, I'm glad to greet you.

I'll explain it visually.

Right now it looks like this: (Width=-1)
Column1 | Column2
09/06/2022 10:0009/06/2022

I wish I could see it like this: (How do I do it, is it possible to do it?)
Column1 | Column2
09/06/2022 10:00 | 09/06/2022
For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
User avatar
BruceSteers
Posts: 1523
Joined: Thursday 23rd July 2020 5:20pm
Location: Isle of Wight
Contact:

Re: Separation between columns of a GridView

Post by BruceSteers »

gambafeliz wrote: Thursday 8th September 2022 3:35pm Hello, Vuott, I'm glad to greet you.

I'll explain it visually.

Right now it looks like this: (Width=-1)
Column1 | Column2
09/06/2022 10:0009/06/2022

I wish I could see it like this: (How do I do it, is it possible to do it?)
Column1 | Column2
09/06/2022 10:00 | 09/06/2022
Did you enable the Grid property to show grid lines? might help.

Other cell/column/row options that could help are
text alignment , you could align left text to left and right text to right
Expand property , this should make all columns equal in size and give you a gap between.
Padding , another way to force a gap.
you could also change Cell background for left and right hand cells , that would make separation clearer

I think you just want Gridview.Grid = True though :)
If at first you don't succeed , try doing something differently.
BruceS
User avatar
gambafeliz
Posts: 139
Joined: Friday 2nd September 2022 7:50pm
Location: I live in the same city as Picasso

Re: Separation between columns of a GridView

Post by gambafeliz »

Thank you all you have said helps.

Honestly, the problem is me, how strange, right? :)

After looking and looking at my code, I notice that I have the automatic width but just before presenting it there is code that I lost that changes that specific width to fixed and for that the problem, please, I apologize.

I have already solved it.

By the way, how do I close this post?
For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Post Reply