6.10b8 ListView line height is much larger

Mac OSX specific forum
WilliamL
Addict
Addict
Posts: 1252
Joined: Mon Aug 04, 2008 10:56 pm
Location: Seattle, USA

6.10b8 ListView line height is much larger

Post by WilliamL »

Does it appear that line height in the ListViewGadget is much larger than in 6.10b7? The example in Help seems to be ok but I'm going to have a lot of editing to get the new size to work and I'd really like the lines not be so tall. In one of my programs in beta 7 I get 70 lines showing and in beta 8 I get 46 lines. Same in several other programs that use LVGs.

Since the Help example seems to work I'm not going to report it as a bug until I get some feedback.
MacBook Pro-M1 (2021), Sequoia 15.4, PB 6.20
Fred
Administrator
Administrator
Posts: 18162
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: 6.10b8 ListView line height is much larger

Post by Fred »

We usually stick to system default, could you put a screenshot of a PB listview and one of another software ?
Lebostein
Addict
Addict
Posts: 826
Joined: Fri Jun 11, 2004 7:07 am

Re: 6.10b8 ListView line height is much larger

Post by Lebostein »

WilliamL wrote: Fri Mar 15, 2024 12:33 am Does it appear that line height in the ListViewGadget is much larger than in 6.10b7? The example in Help seems to be ok but I'm going to have a lot of editing to get the new size to work and I'd really like the lines not be so tall. In one of my programs in beta 7 I get 70 lines showing and in beta 8 I get 46 lines. Same in several other programs that use LVGs.

Since the Help example seems to work I'm not going to report it as a bug until I get some feedback.
Do you happen to change the font of the ListViewGadget? 6.10b7 does the line height shrink to a minimum when you change the font with SetGadgetFont(). See this bug: https://www.purebasic.fr/english/viewtopic.php?t=83723
WilliamL
Addict
Addict
Posts: 1252
Joined: Mon Aug 04, 2008 10:56 pm
Location: Seattle, USA

Re: 6.10b8 ListView line height is much larger

Post by WilliamL »

Lebostein,

I am seeing what you are showing in your image. I was playing with the SetGadgetFont but I didn't figure out the sequence.

This looks like a bug and you've already reported it. Fred said he fixed it so I'll wait and see if he has an update.

Thanks for the info and bug report.

[later]

It looks like in your example that you care changing the font back to the system font in the event loop and that is why the fonts look the same. That doesn't seem to fix the tall spacing. I'm still getting the Geneva 12 point to be 50% taller from beta 7 to beta 8.

Fred (I hope you mean fixed in Beta 9?)

I haven't posted a picture for so long that I'm not sure I remember how. :?
Last edited by WilliamL on Fri Mar 15, 2024 6:35 pm, edited 3 times in total.
MacBook Pro-M1 (2021), Sequoia 15.4, PB 6.20
Fred
Administrator
Administrator
Posts: 18162
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: 6.10b8 ListView line height is much larger

Post by Fred »

The update is in the beta 8 :D
Lebostein
Addict
Addict
Posts: 826
Joined: Fri Jun 11, 2004 7:07 am

Re: 6.10b8 ListView line height is much larger

Post by Lebostein »

It seems it is a hard thing to get back to the default (maybe it is impossible to get all information about the default setup?). Even with the fix on beta 8, you can still see differences between the original state and the reset font.

--------------------

Other strange thing (or is that how Apple specifies it?):

With default, some Gadgets have larger/smaller fonts:
Image

But if you set the font with SetGadgetFont(#PB_Default , FontID(0)) all Gadgets have the same font size:
Image

Code: Select all

LoadFont(0, "San Francisco", 12)
;SetGadgetFont(#PB_Default , FontID(0))

OpenWindow(0, 0, 0, 270, 290, "ListViewGadget", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)

StringGadget  (0, 23,  10, 150, 25, "PureBasic")
TextGadget    (1, 25,  44, 150, 25, "PureBasic")
CheckBoxGadget(2, 5,  70, 150, 25, "PureBasic")
ComboBoxGadget(3, 16, 103, 150, 25)
AddGadgetItem (3, -1,  "PureBasic"): SetGadgetState(3,0)
EditorGadget(4, 21, 137, 150, 50): SetGadgetText(4, "PureBasic")
ListViewGadget(5, 16, 195, 150, 50):AddGadgetItem (5, -1,  "PureBasic"): SetGadgetState(3,0)

Repeat
event = WaitWindowEvent()
If event = #PB_Event_Gadget And EventGadget() = 2: SetGadgetFont(1, #PB_Default): EndIf
Until event = #PB_Event_CloseWindow
HarrysLad
User
User
Posts: 59
Joined: Fri Jun 04, 2010 9:29 pm
Location: Sunny Spain

Re: 6.10b8 ListView line height is much larger

Post by HarrysLad »

I'm using the latest PB release (6.10) and the large vertical spacing in the ListViewGadget is still evident.
Is anyone else seeing this? Or am I missing something?

ATB
Dave
WilliamL
Addict
Addict
Posts: 1252
Joined: Mon Aug 04, 2008 10:56 pm
Location: Seattle, USA

Re: 6.10b8 ListView line height is much larger

Post by WilliamL »

https://www.purebasic.fr/english/viewto ... 45#p618845

mk-soft says and provides a work-around.

In Beta 8, the row height was much too small and has been adjusted.
If this is now too large for you, you can adjust it yourself.


This should make getting all my code to work (as it was) pretty simple.
MacBook Pro-M1 (2021), Sequoia 15.4, PB 6.20
HarrysLad
User
User
Posts: 59
Joined: Fri Jun 04, 2010 9:29 pm
Location: Sunny Spain

Re: 6.10b8 ListView line height is much larger

Post by HarrysLad »

OK, thanks for that WilliamL. I saw the workaround earlier and it seems to work well enough.
It's still a bug though.
Maybe (hopefully) it'll get fixed in the next PB iteration.

Cheers
Dave
Post Reply