Announcement: XUI Framework Release 2

I’m really happy to announce the immediate availability of the XUI Framework, release 2.

In addition to several minor improvements and bug fixes, the biggest addition to this release is the XUIInspector control. This is a versatile control for adding a visual inspector comprised of sections containing items to your desktop apps. It’s super customisable and comes out of the box with the following items:

  • Checkboxes
  • Single text fields
  • Dual text fields
  • Switches
  • Popup menus

With the unencrypted version of the XUI framework you can very easily create your own custom items by implementing a single class interface.

As usual you can read the release notes.

Like all my projects it’s comprehensively documented.

Read more about the XUI framework if you’re interested.

3 Likes

waou thanks looks nice, the only good news of the day…

just when i opened my updated xojo file, it asked me to locate the pictures to garry’s drive
i had to relocate on mine

wierd the new inspectr control doesn’t look the same as you

image

the V icon is touching the side

mac os 13.1

and no matter large i set the width, same plus i have horizontal /vertcal scroll bar, we can disable i guess like on you screen

yes very nice documentation, how it is made for info ?

Couple of questions:

  1. Are you on a HiDPI / Retina or standard monitor? I only have Retina screens so that might be a factor
  2. Could you down load the demo and tell me if the scroll bars are still and issue?

Demo

yes same

macbook 16 i9 +4k screen mac os13,1

I think this must be a scaling issue with your non-Retina monitor.

I’ll have to try to find a standard res monitor and experiment.

Annoying as I thought I had been careful using bitmaps for caching, etc.

demo via catalina via remotedesktop

It looks like the canvas believes there is more content than there actually is (hence the scroll bars). This makes me thinks it’s a HiDPI issue.

I think this has nothing to do with HiDPI. Seems to me that it’s caused by scrollbar settings on macOS.

Screenshot 2022-12-19 at 09.42.25

2 Likes

Thank you @Carsten_Belling!

I just spent the last hour hooking up a standard DPI monitor trying to figure this out and I didn’t even know that setting existed.

I wonder if @Martin_T can help here. The inspector (and the XUI code editor for that matter) are both based on a small subclass of DesktopTextInputCanvas Martin provided me years ago called NSScrollView that interacts with the scrollbars on macOS.

@Martin_T - any thoughts about determining if scrollbars are set to be always on or automatic?

i just got the default settings,
not always

@GarryPettet you never see the scrollbars ?? got a second mac to check ?

I’m sure that there are easier ways to get the scroller style but it works for me:

dim theTextView as new NSTextViewControlMBS
dim theScrollView as NSScrollViewMBS = theTextView.Scrollview
ScrollerStyle = theScrollView.scrollerStyle

@Beatrix_Willius I can’t use MBS as it’s a sold product.

You have the same settings I do @PhilippeP. When I have the system setting put to automatic I don’t see the issue.

I see your exact issue however when I change the settings to show them always.

the only way i don’t see them

can you disable the scroll bar by default ?

plus when verticalscrollbr appears, the colapse icon will be too close to scrollbar anyway

but overall works great, thnaks a lot, will integrate it somewhere

We should be able to translate that into declares if you want.

That’s what I intended with my code.

But you used a Plugin which he said he can’t use.

@GarryPettet:

Declare Function getScrollerStyle Lib "Foundation" Selector "scrollerStyle" (obj As Integer) As Integer

Dim ta As New TextArea // If you use a DesktopTextArea here, change the obj param to "Ptr" above
Dim style As Integer = getScrollerStyle(ta.Handle)

// Style will be 0 for "Legacy" and 1 for "Overlay"

Break

That’s because you’re using a trackpad and Philippe is probably using a mouse. That’s what Apple considers “Automatic” based on the input device.

3 Likes