View previous topic :: View next topic |
Author |
Message |
FreezingFire Admin Team
Joined: 23 Jun 2002 Posts: 3508
|
Posted: Fri Oct 10, 2003 7:59 pm Post subject: Horizontal Radio Buttons/Radios without groups |
|
|
The subject pretty much states the wish but I'd like to see the
ability to use horizontally laid out radio buttons and also the
ability to have them without groups. _________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
Back to top |
|
|
jwfv Valued Contributor
Joined: 19 Mar 2002 Posts: 422 Location: Beaufort, SC
|
Posted: Fri Oct 10, 2003 10:33 pm Post subject: |
|
|
Me too. I could have used them this week on a project, especially the horizontal radio element. I had to rearrange a whole dialog after I just couldn't get it looking right. _________________ Joe Floyd |
|
Back to top |
|
|
Serge Professional Member
Joined: 04 Mar 2002 Posts: 1480 Location: Australia
|
Posted: Fri Oct 10, 2003 11:08 pm Post subject: |
|
|
good idea ff...i could use something like that too
serge _________________
|
|
Back to top |
|
|
FreezingFire Admin Team
Joined: 23 Jun 2002 Posts: 3508
|
Posted: Fri Oct 10, 2003 11:31 pm Post subject: |
|
|
It's just as jfvw said... I couldn't lay out a dialog properly becuase
it wouldn't be horizontal so everything looks crammed in now.
Horizontal styles for them would be great. _________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
Back to top |
|
|
CodeScript Moderator Team
Joined: 08 Jun 2003 Posts: 1060 Location: India
|
Posted: Sat Oct 11, 2003 2:29 am Post subject: |
|
|
I don't think the activex component they are using supports this property. You may need a custom control/component to achieve this . _________________ Regards
- CodeScript
Give your application a professional look with the VDSGUI Extension |
|
Back to top |
|
|
CodeScript Moderator Team
Joined: 08 Jun 2003 Posts: 1060 Location: India
|
Posted: Sat Oct 11, 2003 3:16 pm Post subject: |
|
|
Hi FF
Is this what you are looking for ?
If so you can try this DSU:
http://codescript.vdsworld.com/VDS5src/Radio_Demo.zip
You can adjust the spaces in between etc.
Tested only on XP
Enjoy! _________________ Regards
- CodeScript
Give your application a professional look with the VDSGUI Extension
Last edited by CodeScript on Sat Oct 11, 2003 3:19 pm; edited 1 time in total |
|
Back to top |
|
|
FreezingFire Admin Team
Joined: 23 Jun 2002 Posts: 3508
|
Posted: Sat Oct 11, 2003 3:17 pm Post subject: |
|
|
YES! YES! YES! Exactly! _________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
Back to top |
|
|
Skit3000 Admin Team
Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
|
Back to top |
|
|
CodeScript Moderator Team
Joined: 08 Jun 2003 Posts: 1060 Location: India
|
Posted: Sat Oct 11, 2003 4:52 pm Post subject: |
|
|
Skit3000 wrote: | CodeScript, how did you do it? By using the CreateWindowEx API? |
Nothing big. I just madeout that the items in the Radio are not "light weight controls" but true windows with a hwnd. So just obtain their handles and repostion. Only thing you take care is avoid redrawing of the control using SWP_NOREDRAW flag else the Radio item will be back to it's default (e.g just resize the horizontal style Radio control and see)
No luck with CreateWindowEx API atleast untill the update is out
Also as for FF's question of creating a Radio button without a group:
1. Deselction of other items will not be automatic (U can do it with API).
2. VDS 5.x unlike it's predecessors does not like modifying the controls like that e.g a button to a radio/check (using API) even 1 bit. as it eats up all the required messages on the way.
3. Option MSGEVENT fails on this important message (WM_COMMAND) which gives innumerable GUI possibilies e.g. Adding dockable Rebars, and all those XP stuff.
So I can only say better luck when VDS 6.x is out or go for VDS 4.x.
BTW you can make the group big enough to hold other items like buttons etc so that it looks neat to the user.
I have updated the unit/code to work with Win 9x too. _________________ Regards
- CodeScript
Give your application a professional look with the VDSGUI Extension |
|
Back to top |
|
|
Serge Professional Member
Joined: 04 Mar 2002 Posts: 1480 Location: Australia
|
Posted: Sun Oct 12, 2003 12:43 am Post subject: |
|
|
that is so cool codescript...well done
serge _________________
|
|
Back to top |
|
|
jwfv Valued Contributor
Joined: 19 Mar 2002 Posts: 422 Location: Beaufort, SC
|
Posted: Tue Oct 14, 2003 12:59 pm Post subject: |
|
|
Amazing - you just ask for something in this forum and pretty soon someone says "Ta-da! Something like this?". Really great user community. _________________ Joe Floyd |
|
Back to top |
|
|
DaveR Valued Contributor
Joined: 03 Sep 2005 Posts: 413 Location: Australia
|
Posted: Fri Jan 13, 2006 4:11 am Post subject: |
|
|
Hi CodeScript,
Quote: | From the dsc sample:
Please note the special charcter substituting the space using notepad:
|
I've been playing with your Radio Demo DSU, but I can't see any special character in Notepad
Without the special character I can't get the radio element to look reasonable. I tried copying the space in your example and pasting it into my code, but I ended up getting a "non numeric character" error. _________________ cheers
Dave |
|
Back to top |
|
|
DaveR Valued Contributor
Joined: 03 Sep 2005 Posts: 413 Location: Australia
|
Posted: Fri Jan 13, 2006 5:16 am Post subject: |
|
|
Ok, I changed the font in Notepad to Terminal and I could then see them:
Code: | makhoriz RADIO2,Value 4|Val5ÿ ÿÿ |Val6ÿÿÿ,30,45,10,15 |
But this raises more questions:
What's the difference between: "ÿ ÿÿ " and "ÿÿÿ"
Is ÿ equal to one space
PS I give up! I've tried everything I can think of and I keep getting an error at line 46 in the dsu... _________________ cheers
Dave |
|
Back to top |
|
|
SnarlingSheep Professional Member
Joined: 13 Mar 2001 Posts: 759 Location: Michigan
|
Posted: Fri Jan 13, 2006 6:13 am Post subject: |
|
|
You can input the character by holding ALT and hitting 0 1 6 0 on your number pad on the right.
But some changes to his existing code make it give the non-numeric error, which is really odd..
Also, changing to the line below messes up the alignment completly..
makhoriz RADIO2,Value 4|Val5 @chr(160) |Val6 ,30,45,10,15 _________________ -Sheep
My pockets hurt... |
|
Back to top |
|
|
DaveR Valued Contributor
Joined: 03 Sep 2005 Posts: 413 Location: Australia
|
Posted: Fri Jan 13, 2006 6:36 am Post subject: |
|
|
You'd think I'd have thought of Alt+0160 - since I use Alt+0174 in my sig! Though I'm sure the code was 0+98 in Windows' Character Map (with the Terminal font).
You've struck the same problem(s) I've been having. I either get a non-numeric error, an error at line 46 in the dsu, or completely messed up alignment. _________________ cheers
Dave |
|
Back to top |
|
|
|