Please show your most complex PICTURE

Moderator: Rathinagiri

mrduck
Posts: 497
Joined: Fri Sep 10, 2010 5:22 pm

Please show your most complex PICTURE

Post by mrduck » Sat Dec 03, 2011 6:29 pm

Hi everybody.

3 of us (me, Luigi and Ricci) are discussing and working on prototypes for PICTUREs in Textbox. We are discussing on different approaches and results...

Before going further I'd like to ask EVERYBODY:
- can you please show us the complex PICTUREs do you have in software written with HMG3 library?
- can you please show us the PICTUREs you have in harbour text-only code ?
- is it a big problem if you need to change them ?

User avatar
Rathinagiri
Posts: 5266
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 171 times
Been thanked: 173 times
Contact:

Post by Rathinagiri » Sun Dec 04, 2011 4:34 am

Hi Francesco,

In my programs I don't use complex pictures a lot.

However, I use/prefer date textbox in the place of calendar which reduces the key strokes.

My numeric textbox would have a picture like this '9999999.999'. That's all.

Recently I have used this picture for a specific purpose:

inputmask 'AAAAA9999A'
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 182 times

Post by Pablo César » Sun Dec 04, 2011 11:03 am

PICTUREs in Textbox... ? I never used it. Well I am just starting in GUI world, I begin in begining of 2011, so I do very simple codes but It will be very good to have it. This would be something like this ?

Image

I have took that picture from internet.

Another thing that could it be interesting is inserting text boxes in pictures.

I also read some comments that could it be interesting to be considered:
Where the picture is?

1. Will there be a border around the outside edge of the text (i.e., between the text and the edge of the physical page)? If so, you can do this using a page border. If not... ignore this step.

2. Do you want a border that separates the text from the picture? If you want white space between that border and the picture, as well as between that border and the text, you can do this by inserting a rectangular shape, and setting its wrapping style to square or tight.

3. You then insert the picture, and set its wrapping style to In front of text, and drage the picture so that it's overlayed on top of the rectangular shape that provides the border.
Last edited by Pablo César on Sun Dec 04, 2011 11:24 am, edited 2 times in total.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

mrduck
Posts: 497
Joined: Fri Sep 10, 2010 5:22 pm

Post by mrduck » Sun Dec 04, 2011 11:21 am

I was asking PICTURE of the
@ GET PICTURE <sample>

not including images in textboxes.... :-)

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 182 times

Post by Pablo César » Sun Dec 04, 2011 11:32 am

Ohhh so sorry ! I have missunderstood ! Very sorry.

Well here in Brasil we use for exemple:
- Nums: 1.000,50 (one thousand and fifty) this also valid for money. In Clipper I've used "@E 999,999.99". It would it be wounderful to use like elctronical cash of banks, type each numbers and be aligned from right to left considering comma as decimals.
- Date: "@D" in this format dd/mm/yyyy - Set British way. But the claendar is great !
- For social ID: "999.999.999-99"
- For upper cases: "@!"
- Now for emails picture, we know shoulkd it be in lower case with noespecial caracters and exemptions.
- Some modifications in GETSYS.PRG in Clipper was used to do it for lower cases pictures, using Picture "@M".
- Also in Clipper for string I have used much "@!S30" combined case, upper + subs tring showing just 30 characters. Other char picture is "!AAA" combined upper and only alpha characters.
- For passwords, must be showing a pre-defined character "*" (for example)
- For telephone numbers (but string one): "#999-9999" first character could it be in blank (one space).
- And for numbers that no appears on screen when value is zero, usedin CLipper: "@Z 999" shows in blank.

Well, I hope be helpfully for your concepts. Thank you for your attention and dedication too.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

Marco
Posts: 2
Joined: Wed Nov 09, 2011 5:13 pm

Post by Marco » Mon Dec 05, 2011 9:01 am

hi all,
I also don't use complex picture.
For me the maximum is like '99!!!999" or "99-AAA-999" to input codes for inventory items.
Thanks for your fantastic work I'm only at my third month with hmg so I read all but I can't post cause my ignorance.

User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Post by l3whmg » Sun Dec 11, 2011 6:50 pm

Hi to everyone.
I'm working on TEXTBOX. In this moment I have a working experiment based upon "some" HMG3 codes: "!", "A", "N", "X", "9" (obviously with ".", ",", "+","-"). As soon as possible I will share exe to show.

To manage entered data there are many possibilities, as you can see can be implemented with validator (see MrDuck commit), but I have a question related with this topic: do you think it's better to respect HMG3 (it has a reduced set of code), CLIPPER (it has some "strange" or "unused" or "unusefull" code), strictly QT inputmask (see this http://doc.qt.nokia.com/latest/qlineedi ... tMask-prop ) or create a mixed? If we use the last two (Qt inputmask or a mix) we can't use some CLIPPER function (f.e. TRANSFORM) and we must create a new set of functions (f.e. Hmg_Transform).

Cheers
Luigi from Italy
www.L3W.it

User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Post by l3whmg » Mon Dec 12, 2011 12:49 am

Hi friends.
post revised on 2011.12.15

I'm very pleased to show you my last improvement of TEXTBOX object.
I have solved some problem and the first one is about DATATYPE (thanks to MrDuck, he said me: try to find a solution); now, there isn't need to set this value as parameter within the New() method.
On the other hand, this setting cannot be changed after object creation.

OOP syntax accpeted (I will show only specific for textbox )

Code: Select all

   WITH OBJECT [oVarName := ] TEXTBOX():New( [cObjectName][,oParent] )
      [:InputMask    := "......."]
      [:Format       := [E | C | X | ( | S] ]
      [:DataType     := [TXT_CHARACTER | TXT_NUMERIC | TXT_DATE] ]
      [:CaseConvert  := [TXT_NONE | TXT_UPPER | TXT_LOWER] ]
      [:MaxLength    := <number> ]
      :Value         := [<string>, <number>, <date>]
   END WITH

InputMask:
A) Can be always omitted. About TXT_DATE will be used "SET( _SET_DATEFORMAT )" returned value

B) TXT_DATE acceppeted character code:
  • ["YYYY" | "YY"]: year position
    "MM" : month position
    "DD" : day position
any other character will be considered a valid separator, but you must refer your "PICTURE" clause to Harbour valid dates handling. In other words: if Harbour functions can't handle the date it will be considered a wrong date. f.e. Italian style is "DD-MM-YYYY" or "DD-MM-YY"; USA style is "MM/DD/YYYY" or "MM/DD/YY"; ISO is "YYYY.MM.DD".
n.b. if a wrong date is entered only when TEXTBOX object lost focus an error occurs.

C) acceppeted character code:
  • "!" : convert uppercase alphabetic character
    "A" : alphabetic (a-z, A-Z)
    "9" : digit (0-9). About TXT_NUMERIC "+" and "-" are accepted
    "N" : digit (0-9) and alphabetic (a-z, A-Z)
    "X" : any character
    "," : with TXT_NUMERIC to format displayed value
    "." : with TXT_NUMERIC to format displayed value and to know if decimals are present while editing
reserved, internal, don't use: "D"

Format:
n.b. only for numeric datatype are used
  • "E" : swap "." and "," to show numbers in European format (eg. "1.234.567,89"). By default is English-speaking format (eg. "1,234,567.89")
    "C" : displays "CR" after positive numbers
    "X" : displays DB after negative numbers
    "(" : encloses negative numbers in parentheses
    "S" : new always displays sign for positive or negative numbers
DataType:
Can be omitted: in this case, will be set with related value VALTYPE.
Behaviour:
  • A) when TEXTBOX object will be created cannot be changed
    B) if already set and value VALTYPE is not compatible an error occurs
    C) if set after value assignment and is not compatible with value VALTYPE an error occurs
About BACKSPACE and DEL usage:
  • * While editing TXT_NUMERIC field you can use both. Also character selection (one or more) can be used.
    * While editing TXT_CHARACTER field:
    • - without InputMask: you can use both. Also character selection (one or more) can be used.
      - with InputMask: BACKSPACE not allowed, DEL only if all the characters are selected
    * While editing TXT_DATE field: only DEL if all the characters are selected
Remember: this is a working experiment realized with my personal library.

I'll wait your opinion and then if liked it As Soon As Possible and in according with MrDuck's job (he is working on the same object), I will change current HMG4 TEXTBOX object.

Cheers
Attachments
demo01_t.zip
demo 2011.12.15 update
(1.05 MiB) Downloaded 128 times
Last edited by l3whmg on Thu Dec 15, 2011 12:16 pm, edited 6 times in total.
Luigi from Italy
www.L3W.it

User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Post by l3whmg » Wed Dec 14, 2011 10:45 am

Hi friends.
I have upload a new version of my experiment.
Cheers
Luigi from Italy
www.L3W.it

User avatar
Rathinagiri
Posts: 5266
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Has thanked: 171 times
Been thanked: 173 times
Contact:

Post by Rathinagiri » Wed Dec 14, 2011 12:12 pm

Hi Luigi,

I have tested the sample Luigi. It is working as expected. :) Thanks man.

So, we have to write the validation of date. (Now it accepts any invalid date too.)
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.

Post Reply