Has anyone already written a length-of-time entry control?

8 views
Skip to first unread message

lifeatt...@gmail.com

unread,
Mar 17, 2022, 1:22:49 PM3/17/22
to fltk.general
I want a "smart" length-of-time entry control. Hours:minutes:seconds.

"Smart" meaning if the user enters "70" in the minutes portion, it updates
to "1:10:00".

Ideally with a spinner, but I'm undecided on how it would work -
a. Spinners per section
b. one spinner, changes the section with input focus

My thanks in advance!
Kevin

Albrecht Schlosser

unread,
Mar 17, 2022, 2:42:31 PM3/17/22
to fltkg...@googlegroups.com
On 3/17/22 18:22 lifeatt...@gmail.com wrote:
> I want a "smart" length-of-time entry control. Hours:minutes:seconds.
>
> "Smart" meaning if the user enters "70" in the minutes portion, it updates
> to "1:10:00".

I have nothing specific to offer here, but there are some thoughts...

> Ideally with a spinner, but I'm undecided on how it would work -
> a. Spinners per section
> b. one spinner, changes the section with input focus

I think this depends on the covered time range.

A bad design example: in an app where you enter a date there are three
distinct widgets equivalent to Fl_Choice where you can select day,
month, and year separately (this could be compared to your h/m/s input).
It's annoying to have to access three separate widgets in this case.

I would suggest to have three different spinners for hours, minutes, and
seconds and use overflow/underflow mechanisms to "flow" from one spinner
to the next higher one at overflow or underflow, i.e. the "smart" aspect
would be if you spin the seconds up over 59 it would wrap to 0 and
increment the minute by one etc.

I have no suggestions concerning numerical input though.

But that's only my personal opinion as a potential user and not as a
professional GUI designer.

Reply all
Reply to author
Forward
0 new messages