-
April 16th, 2014, 03:54 AM
#1
[RESOLVED] MFC Application UI develop idea
I'm on a process to build a new application which will have left menu and corresponding screens for each button. You can say a Vertical tab like interface. For a more clear picture I have prepared a simple layout using resource editor which has been attached.
Now what would be the good approach to do it? Currently I'm following simple way to do this ie: One main dialog which owns all left menu buttons and show/hide child dialogs for each button within right area.
Do note that I will apply background images on dialog and buttons so that my application gets a nice GUI.
◄◄ hypheni ►►
-
April 16th, 2014, 04:14 AM
#2
Re: MFC Application UI develop idea
Victor Nijegorodov
-
April 16th, 2014, 04:33 AM
#3
Re: MFC Application UI develop idea
Never used this class. Time to learn something new.
◄◄ hypheni ►►
-
April 16th, 2014, 04:39 AM
#4
Re: MFC Application UI develop idea
Good luck!
Victor Nijegorodov
-
April 16th, 2014, 06:36 AM
#5
Re: MFC Application UI develop idea
VictorN Sir .. if we select Form Programming ( c# ) for above application or Visual Express .. Will it be simpler than property page ?
For left side buttons , can we work without Dialog ?
Just a querry .. !!
-
April 16th, 2014, 07:13 AM
#6
Re: MFC Application UI develop idea
Originally Posted by new_2012
VictorN Sir .. if we select Form Programming ( c# ) for above application or Visual Express .. Will it be simpler than property page ?
I don't know. I never used c# for UI programming. Nor used I any other Form Programming language.
Victor Nijegorodov
-
April 16th, 2014, 07:47 AM
#7
Re: MFC Application UI develop idea
Actually the UI can be achieved by many ways ie: Painting method, Creating child dialog and as said by VictorN by Property page method. What ever you want. I don't know C# but you can do it easily with any framework.
I think I will go for Painting method / Child dialog method as I don't find much interest on property sheet. All I can do by handling events and making custom buttons and controls.
◄◄ hypheni ►►
-
April 16th, 2014, 09:23 AM
#8
Re: MFC Application UI develop idea
I'd do it with buttons and nested dialogs.
-
April 16th, 2014, 11:58 AM
#9
Re: MFC Application UI develop idea
Originally Posted by hypheni
I think I will go for Painting method / Child dialog method as I don't find much interest on property sheet. All I can do by handling events and making custom buttons and controls.
Sure, you can do it this way, but it's the hard way to get it done unless you really need something custom.
-
April 16th, 2014, 01:39 PM
#10
Re: MFC Application UI develop idea
Yes. I do need all custom buttons and all. I need to place images on buttons and dialogs. And for me it will be faster.
Currently what I have done is, created one parent dialog which has all the left menu item buttons. On clicking any of them opens a corresponding dialog as child dialog (CreateDialog ie: Modeless). Now once this dialog is opened inside parent dialog, if I drag the parent dialog this child dialog is not moving along with. Also the focus is set to child dialog (I know this should be default behavior). What could be done in this context.
I have other option to make separate class / function for each menu and draw to one dialog according to menu item selected.
◄◄ hypheni ►►
-
April 16th, 2014, 01:42 PM
#11
Re: MFC Application UI develop idea
Originally Posted by hypheni
Yes. I do need all custom buttons and all. I need to place images on buttons and dialogs. And for me it will be faster.
Currently what I have done is, created one parent dialog which has all the left menu item buttons. On clicking any of them opens a corresponding dialog as child dialog (CreateDialog ie: Modeless). Now once this dialog is opened inside parent dialog, if I drag the parent dialog this child dialog is not moving along with. Also the focus is set to child dialog (I know this should be default behavior). What could be done in this context.
I have other option to make separate class / function for each menu and draw to one dialog according to menu item selected.
Again, nested dialogs.
-
April 16th, 2014, 11:46 PM
#12
Re: MFC Application UI develop idea
Yes nested dialog. But current my child dialog wont have any title bar. So user wont understand by view that its a child dialog. But what my problem is: Im not able to move the child window along with parent.
Should I post MouseMove message to child when its received by the parent dialog.
◄◄ hypheni ►►
-
April 17th, 2014, 11:50 AM
#13
Re: MFC Application UI develop idea
Originally Posted by hypheni
Yes nested dialog. But current my child dialog wont have any title bar. So user wont understand by view that its a child dialog. But what my problem is: Im not able to move the child window along with parent.
Should I post MouseMove message to child when its received by the parent dialog.
We got it, but we're trying to explain it to you. Use a nested dialog and set the child style for the child dialog. When you get the styles for the child correct, it will be embedded without a title and move along with the parent dialog (and of course you need to pass the parent cwnd to the child when you create it). No need to handle the MouseMove message or any other because it's taken care of for you. If you can't figure out the correct styles for the child dialog, find a property sheet/page (CPropertySheet/CPropertyPage) example on the net and look at the styles for the dialog on each page. Those same style settings will work in your case.
-
April 17th, 2014, 10:47 PM
#14
Re: MFC Application UI develop idea
Thank you all .. as I learnt a lot from your post .
Will you please guide me , how to use any of the Dialog Control on main window ? I have used all the controls in Dialog only.
But how to use them on Main Program Window ?
I needed a button control on my screen .. I draw a bitmap . Checked mouse click and take necessary action. How to do this with
actual Button Control on Screen ?
I will learn to place Images on controls .. It is bit difficult in VC++ but simple with Form Programming
-
April 17th, 2014, 11:49 PM
#15
Re: MFC Application UI develop idea
Originally Posted by new_2012
Thank you all .. as I learnt a lot from your post .
Will you please guide me , how to use any of the Dialog Control on main window ? I have used all the controls in Dialog only.
But how to use them on Main Program Window ?
I needed a button control on my screen .. I draw a bitmap . Checked mouse click and take necessary action. How to do this with
actual Button Control on Screen ?
I will learn to place Images on controls .. It is bit difficult in VC++ but simple with Form Programming
Read some tutorials on Internet for getting the whole VC++ dialog based programming. What you need to do is Create a dialog from resource editor and draw a button from the toolbox there. Then you will have add a button handler and process further.
For ref: http://www.functionx.com/visualc/controls/dialogbox.htm
Simply googling can reveal you a lot of stuff about this.
◄◄ hypheni ►►
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|