CHDK - virtual keyboard - testers needed! - page 15 - General Discussion and Assistance - CHDK Forum

CHDK - virtual keyboard - testers needed!

  • 150 Replies
  • 49011 Views
*

Offline reyalp

  • ******
  • 14125
Re: CHDK - virtual keyboard - testers needed!
« Reply #140 on: 28 / February / 2012, 16:09:49 »
Advertisements
It was sugested somewhere before and I think it's good idea. This will avoid safe checks with each user entered text. But is it possible to do this not breaking compatibility with previous version?

If there's no such possibility I'm still for it, but the best would be to have back compatibility :)
Don't worry about backward compatibility in the trunk. That's why we have an release and unstable branches.

edit:
Of course if you can make it backward compatible without introducing a bunch of ugliness, that's great.
« Last Edit: 28 / February / 2012, 16:23:18 by reyalp »
Don't forget what the H stands for.

Re: CHDK - virtual keyboard - testers needed!
« Reply #141 on: 01 / March / 2012, 10:06:06 »
An option to make it backward compatible is to make separate functions and not flags.

I have for approximately a week no camera but after that I will try to implement one of this (flags or functions).

Re: CHDK - virtual keyboard - testers needed!
« Reply #142 on: 06 / March / 2012, 04:56:18 »
Yes, I think extend with new function is good idea.

No problem with reconcile any changes in the module. This is what is API_VERSION purposed for.
If you will add new functions then increase minor version of api version in libtextbox.
If your changes will be backward incompatible, then increase major num in api version

Details are here
http://chdk.wikia.com/wiki/Module_System#API_versioning_system

Re: CHDK - virtual keyboard - testers needed!
« Reply #143 on: 17 / April / 2012, 14:13:25 »
Now I have a new idea: I think it's better to make more input boxes (e.g. intBox, listBox ...) and no flags, because then the code is easier and only the really needed modules must be loaded.

Re: CHDK - virtual keyboard - testers needed!
« Reply #144 on: 17 / April / 2012, 17:04:37 »
I like it... it's Unix-like philosophy - let's have a lot of programs, where every one can do only one thing, but it does it well. So we could have such boxes:

- textBox - what we have now
- intBox - for numbers
- floatBox  - float numbers (one dot)
- listBox - check one item
- filenameBox - only 8+3 filenames
if (2*b || !2*b) {
    cout<<question
}

Compile error: poor Yorick

Re: CHDK - virtual keyboard - testers needed!
« Reply #145 on: 12 / May / 2012, 15:54:17 »
I have finished a number input box (double/int).
You can apply the patch in the attachment and try it.
If you select _nbox.flt you can enter a number between -1.5 and 5.7 (only for testing)

The function "doublebox_init" to input double values or "intbox_init" to input int values.
On cancel the callback is called with "max value + 1".

Re: CHDK - virtual keyboard - testers needed!
« Reply #146 on: 22 / May / 2012, 06:31:12 »
Here is a patch to add "_" and "£" to the textbox.

*

Offline srsa_4c

  • ******
  • 4451
Re: CHDK - virtual keyboard - testers needed!
« Reply #147 on: 21 / December / 2014, 08:38:19 »
I have found a bug (only found it because it was causing a visible display glitch on the sx280 due to the higher resolution). The placement of the right "long text marker" was wrong.
Patch attached (should work for both 1.3 and trunk). I'm not committing it because there might be other issues I did not notice.

*

Offline philmoz

  • *****
  • 3450
    • Photos
Re: CHDK - virtual keyboard - testers needed!
« Reply #148 on: 22 / December / 2014, 00:22:37 »
I have found a bug (only found it because it was causing a visible display glitch on the sx280 due to the higher resolution). The placement of the right "long text marker" was wrong.
Patch attached (should work for both 1.3 and trunk). I'm not committing it because there might be other issues I did not notice.

I'm not sure I see the issue.
As far as I can tell the patch does not change the functionality.

If maxlen < MAX_TEXT_WIDTH then you can't input a string that won't fit on the screen so you should never see the markers.
If maxlen >= MAX_TEXT_WIDTH then fldlen == MAX_TEXT_WIDTH and the code is the same as before the patch.

What am I missing here?

Phil.
CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)
  g5x (1.00c, 1.01a, 1.01b)
  g7x2 (1.01a, 1.01b, 1.10b)

*

Offline srsa_4c

  • ******
  • 4451
Re: CHDK - virtual keyboard - testers needed!
« Reply #149 on: 22 / December / 2014, 11:08:03 »
I'm not sure I see the issue.
As far as I can tell the patch does not change the functionality.
My description was not accurate enough. The problem happens when the right marker is not shown. The rest of my patch can be regarded as noise.

else draw_char(text_offset_x+MAX_TEXT_WIDTH*FONT_WIDTH, text_offset_y, ' ', MAKE_COLOR(COLOR_GREY, COLOR_GREY));

 

Related Topics


SimplePortal © 2008-2014, SimplePortal