Showing four options in a menu?

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Showing four options in a menu?

Geoff Canyon via use-livecode
For displaying a simple binary choice in a menu, a !c checkmark works well.
But in Navigator's property menu, there are four possibilities:

1. the property is not boolean -- display nothing with the menu.
2. the property is boolean and is true for all the selected controls --
display a !c check.
3. the property is boolean and is false for all the selected controls --
display ???
4. the property is boolean and is false for some of the selected controls
and true for others -- display ???

Is there any way to handle this without a sub-menu? It would be nice to be
able to set booleans from the menu just by selecting them instead of having
to mouse onto  a sub-menu.
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Showing four options in a menu?

Geoff Canyon via use-livecode


> On Oct 15, 2018, at 13:57 , Geoff Canyon via use-livecode <[hidden email]> wrote:
>
> For displaying a simple binary choice in a menu, a !c checkmark works well.
> But in Navigator's property menu, there are four possibilities:
>
> 1. the property is not boolean -- display nothing with the menu.
> 2. the property is boolean and is true for all the selected controls --
> display a !c check.
> 3. the property is boolean and is false for all the selected controls --
> display ???
> 4. the property is boolean and is false for some of the selected controls
> and true for others -- display ???
>
> Is there any way to handle this without a sub-menu? It would be nice to be
> able to set booleans from the menu just by selecting them instead of having
> to mouse onto  a sub-menu.

It would be non-standard, but that being said, prepending the menu with a character like a bullet, checkbox, x or dash could work. Not sure if button/menu text can display HTML, but that would be a possibility. You would have to handle your selections differently methinks.

Bob S


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Showing four options in a menu?

Geoff Canyon via use-livecode


> On Oct 16, 2018, at 08:51 , Bob Sneidar via use-livecode <[hidden email]> wrote:
>
>
>
>> On Oct 15, 2018, at 13:57 , Geoff Canyon via use-livecode <[hidden email]> wrote:
>>
>> For displaying a simple binary choice in a menu, a !c checkmark works well.
>> But in Navigator's property menu, there are four possibilities:
>>
>> 1. the property is not boolean -- display nothing with the menu.
>> 2. the property is boolean and is true for all the selected controls --
>> display a !c check.
>> 3. the property is boolean and is false for all the selected controls --
>> display ???
>> 4. the property is boolean and is false for some of the selected controls
>> and true for others -- display ???
>>
>> Is there any way to handle this without a sub-menu? It would be nice to be
>> able to set booleans from the menu just by selecting them instead of having
>> to mouse onto  a sub-menu.
>
> It would be non-standard, but that being said, prepending the menu with a character like a bullet, checkbox, x or dash could work. Not sure if button/menu text can display HTML, but that would be a possibility. You would have to handle your selections differently methinks.
>
> Bob S
>
>
The answer is no, a button cannot display HTML. If it did then some thought would have to be given to how to return a value in menuPick. You wouldn't want it to return the html text of the choice, but then how would you distinguish what part of the value was the mark, and what was the choice?

In these situations, I usually go away from popup menus and use locked fields with listBehavior set instead.

Bob S



_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Showing four options in a menu?

Geoff Canyon via use-livecode
I went with submenus, and that works, it's just annoying for a binary value
(even if binary really ends up being four options, as described). I'm going
to leave it alone for now and wait for inspiration to hit.

On Tue, Oct 16, 2018 at 8:58 AM Bob Sneidar via use-livecode <
[hidden email]> wrote:

>
> In these situations, I usually go away from popup menus and use locked
> fields with listBehavior set instead.
>
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Showing four options in a menu?

Geoff Canyon via use-livecode
In reply to this post by Geoff Canyon via use-livecode
On Tue, Oct 16, 2018 at 7:58 AM Geoff Canyon via use-livecode
<[hidden email]> wrote:

>
>
> 1. the property is not boolean -- display nothing with the menu.
> 2. the property is boolean and is true for all the selected controls --
> display a !c check.
> 3. the property is boolean and is false for all the selected controls --
> display ???
> 4. the property is boolean and is false for some of the selected controls
> and true for others -- display ???
>
For may programs, particularly with reference to Font settings, if you
select text containing a multitude of font formats it will show a
minus sign '-' as it can't show multiple values.  If it were me:

2 = tick in the Box
3 = x in the Box
4 = - in the Box.

It might not be quite standard but I think most people would figure it
out pretty quickly.

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Showing four options in a menu?

Geoff Canyon via use-livecode
Woot! I never considered using unicode! (not that you actually typed the
word, but that's what I took from your comment)

My working copy of navigator now has:

An empty box for all false
A - in a box for mixed
A check in a box for all true.

Thanks!

On Wed, Oct 17, 2018 at 3:08 PM Kay C Lan via use-livecode <
[hidden email]> wrote:

> On Tue, Oct 16, 2018 at 7:58 AM Geoff Canyon via use-livecode
> <[hidden email]> wrote:
> >
> >
> > 1. the property is not boolean -- display nothing with the menu.
> > 2. the property is boolean and is true for all the selected controls --
> > display a !c check.
> > 3. the property is boolean and is false for all the selected controls --
> > display ???
> > 4. the property is boolean and is false for some of the selected controls
> > and true for others -- display ???
> >
> For may programs, particularly with reference to Font settings, if you
> select text containing a multitude of font formats it will show a
> minus sign '-' as it can't show multiple values.  If it were me:
>
> 2 = tick in the Box
> 3 = x in the Box
> 4 = - in the Box.
>
> It might not be quite standard but I think most people would figure it
> out pretty quickly.
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode