ChrysaLisp icon indicating copy to clipboard operation
ChrysaLisp copied to clipboard

UI/UX design suggestions.

Open nuclearfall opened this issue 4 years ago • 17 comments

These are just some thoughts I've had concerning the GUI. These shouldn't be considered priority items. I may choose one or two that I think I can complete in the cscript.

I've been considering the titlebar of the window. It seems like having a toolbar class that acts as a titlebar for windows my be a better option. It would eliminate special functions like window-set-title for the more universal (set window 'text "title"). This would allow for different flows to be set, having toolbars at the bottom or on the side of a window.

If this were implemented with fullscreen windows, it could provide a customizable toolbar for the gui without the need to access the screen view at all, as it's just a window. Which leads to the point of styling.

Certain things like padding of elements would be useful in UI design. If styling issues like 'color 'ink_color and the like are kept in a separate class it would make markdown readers, with or without css, much easier to write.

Specific component-connect functions could be kept in a class library for things that are oft used. Things like closing a window, maximizing or full-screening a window, could be accessible as single functions, like hide-window. This allows the ability to expand that library to things like opening a dialog or viewing a hidden field or window without the need to recreate boiler plate code.

I would write a library of boiler plate if you think it would be better implemented in ChryaLisp instead of at the gui/ level. But, I think the point of keeping things at a lower level was to improve efficiency?

That brings me to another point. Am I correct that hide-window function does what it says, and does not close the window? Is it possible to retrieve or show-window things that have been "closed." If this were implemented at the component level, would it allow hiding and showing of any widget? Is this a complicated matter? This allows for hiding and showing toolbars and views creating more dynamic UX.

Pardon any suggestions that are already implemented and I've not found them.

A bit of a checklist for UI/UX design and implementation.

  • [x ] sane defaults that allow users to simply (ui-tree window (create-window).
  • [ ] automatically place windows in a cascading fashion from the previous window unless a user explicitly requests a specific position.
  • [x] add fullscreen mode and/or no_titlebar and undecorated flags.
  • [ x] eliminate certain widget specific functions where more universal functions are sufficient. This allows easier adaptability for different widgets.
  • [ ] hide/show component functions or style options.
  • [x] implement percentage based flows to allow all views/components to be scaled. I think the background already does something similar?
  • [x] implement styling as separate from a specific class to avoid hardcoding things like default 'fonts. Add padding and margins to components.
  • [x] create a certain number of fonts globablly upon start-up so that they may be used without creating fonts for specific views. 'font and 'font_size.
  • [x] Implement buttons as views to easily enable the creation of image buttons or film buttons. This would create cohesion for buttons, instead of requiring creation of a pseudo-button.
  • [ ] implement hide and show at the component level to allow easily hiding and showing windows/buttons/etc.
  • [x] Make determinations on what should be implemented at the gui class level and what should be implemented in lisp as a boilerplate library using the gui classes.
  • [ ] Keyboard chords macros using modifier keys.
  • [x] Mouse down/mouse up/right-click events.

Again, these are merely suggestions, and I will be happy to help given time and my own limitations.

nuclearfall avatar Mar 30 '20 14:03 nuclearfall

It looks as though you've already created a button bar with macros. That's great.

nuclearfall avatar Mar 30 '20 14:03 nuclearfall

I’ll comment more soon on this list. Probably when I’m free over the weekend.

But I’m definitely keen on some changes to the GUI to simplify things.

New layouts and extra macros to help build standard components and so forth can go a long way. I like the idea of removing the title and status bars from a window object. Macros that build standard Windows that have titles and status etc rather than a component that has those methods.

I have been wanting a shake up here for a while. Still class the GUI as experimental.

vygr avatar Mar 31 '20 21:03 vygr

That sounds good.

If there are ways in which I can help that are mundane tasks occupying time in ways better spent elsewhere, I have some non-zero amount of time most days where my cognition is poor, but I can still function enough to do some thing.

nuclearfall avatar Apr 01 '20 17:04 nuclearfall

Push the simplification of window component to be just a resizable panel.

Macros for stand window types will come soon.

vygr avatar Apr 02 '20 18:04 vygr

I think the separation is great.

I've been going through the class.vp code for the gui classes and I was considering experimenting with moving the drag functionality to the component level so that all components have access. That would also make the titlebar just a flow with a label and a few buttons.

What do you think about this idea?

nuclearfall avatar Apr 03 '20 19:04 nuclearfall

I just push a load of changes!

One of those was making the title bar just a flow, but I need to think on the drag issue.

I think you will like the changes ! Well I hope so :)

vygr avatar Apr 04 '20 13:04 vygr

None of the theamable properties are baked in at the VP level now. So you no longer need to rebuild etc just to change a colour or size default. And that’s per user too in the pupa file.

vygr avatar Apr 04 '20 13:04 vygr

Pushed title flow macro and default fonts env settings.

vygr avatar Apr 05 '20 11:04 vygr

UI-window macro now provides a flow_down_fill as standard.

vygr avatar Apr 05 '20 12:04 vygr

Ui-scroll macro added and some other tidy ups.

I’m going to let this settle for a while now. See how it feels for the week.

Generally with Lisp I find that you add stuff and things build to the point you notice repeating patterns in data or source and once that happens it’s time for a macro or set of macros to take all the repetitive slog away !

vygr avatar Apr 05 '20 16:04 vygr

I think that's probably a good call. I like the changes that you've made with the environment styling.

nuclearfall avatar Apr 05 '20 20:04 nuclearfall

Added an optional list parameter to (ui-buttons) that stores each button ref as it’s created.

This makes it easy to do radio selections etc.

vygr avatar Apr 14 '20 09:04 vygr

I think we can update the checkboxes now.

The create a number of fonts up front one is definitely done.

Chris

vygr avatar Apr 30 '20 14:04 vygr

I dropped off for a bit. Went through and checked some of the boxes. Let me know if there are more that you think should be checked off, or any that you think are unlikely to be completed or unnecessary.

I started a repo for fonts here: https://github.com/nuclearfall/CTFonts

nuclearfall avatar May 06 '20 21:05 nuclearfall

How’s the foot ?

vygr avatar May 07 '20 15:05 vygr

Added a (pii-dirlist) function so we can easily enumerate any fonts in the fonts folder. Plus we need something to tide us over till the real file system arrives.

vygr avatar May 08 '20 13:05 vygr

Ticked the:

implement percentage based flows to allow all views/components to be scaled. I think the background already does something similar?

As we can now do this easily and apps can have custom layouts purely in Lisp.

vygr avatar Nov 13 '20 13:11 vygr

Until someone who has an actual skill in UI design decides to help out you will get what I knock up. :)

vygr avatar Dec 02 '23 15:12 vygr