Currently we are using Xtreme Toolkit Pro Grid control with virtualization support for our application to show the contents in Grid. Is there any other better software which can be easily used as Grid without much changes in the application.
Also can I able to achieve the full use of Grid in CMFCPropertyGridCtrl which is present in MFC feature pack.
Depends on what you call 'better'. What do you need it to do what your current solution doesn't.
Answer to your second question is 'no'.
try http://www.bcgsoft.com their grid is much better:
http://www.bcgsoft.com/featuretour/tour194.htm
we're using it for a long time.
Related
I just started developing an MFC application for the first time and I'm hoping to get more familiar with the whole "controls" concept. I am using the dialog editor in visual studio and so far I was not able to find functionality to add a simple table/grid. It seems quite basic to me, but I can't even find reliable information on how to do it on the internet.
I am looking for something similar to Qt's QTableWidget, something that I can later program with variable amount of rows and columns tailored to my application's use cases.
Do you have any ideas how to do it?
I use CGridCtrl which is very powerful and does a lot of the legwork for you.
Sounds like you're after a List View Control, which is wrapped by MFC's CListCtrl class. The dialog editor will enable you to add one and set its properties.
I was frustrated because I know StackPanel wasn't in the MFC.
I'm making a UI, and I have to stack the controls vertically.
If i'm using WPF, I can use StackPanel, but I'd like to ask you some advice on how to do it in MFC.
thnk you very much
There is nothing in MFC that implements the functionality of a StackPanel. If you want to stack controls, you're going to have to do it yourself, either in code or the resource editor.
Starting with Visual Studio 2015, MFC was updated to include support for Dynamic Layout. That helps automatically re-arrange controls when a dialog is resized, but still doesn't get you the entire functionality of a StackPanel.
With MFC you have to do this manually or find third-party code that does it for you. E. g. have a look on CodeProject.
To do layouting on your own, you have to know how much space each control requires to show its content unclipped.
Some controls have methods to calculate their "ideal" size, e. g.:
CButton::GetIdealSize()
CRichEditCtrl::RequestResize(), Calculating a Rich Edit Control Minimum Size
Some controls like CStatic don't provide such methods. In such cases you may succeed to calculate their size using CDC::DrawText() with flag DT_CALCSIZE (don't forget to select the font of the control into the device context first to get accurate measurements).
In other cases, where such calculations are not possible, you may assume a fixed size for a control.
I need to develop a search module for an mfc ribbon application using C++. I have used auto complete feature in C#.NET but never worked on any mfc ribbon application. I want auto complete search with an icon image as prefix of each suggestion, just like Facebook search. I have also consulted this article, but that uses CComboBox, I need to use CMFCRibbonCombobox in my program because I tried with CCombobox but that was causing problems. Any help will be appreciated.
you need to create your own CMFCRibbonComboBox derived class, that will be pretty much a copy of the CMFCRibbonFontCombBox without the fonts.to check how you draw the images you can check the CMFCRibbonFontComboBox::OnDrawDropListItem implementation.
Then I think that you will have to dynamicaly add it to the ribbon.
when wx.Dialog is created it can take any position on the computer screen and take any dimension if style allows. I am trying to build dialogs and confine them within the application window.
I am not sure if my question is clear, I guess an online imagine would be a good example of what I need to do.
in the current link, "spectra analysis" is an exact example of what I need.
http://cdn.altrn.tv/s/b80a7d76-3293-45f2-84dc-07ae136df1c6_1_full.gif
The UI in the image is using the Multiple Document Interface, and in wxPython on Windows you can get the same UI by using the wx.MDIParentFrame and wx.MDIChildFrame. However be sure this is what you need because most users do not like MDI and even Microsoft abandonded it in their applications long ago.
You don't want dialogs. You most likely want to look at the AUI widgets. There are the old wx.lib.aui widgets and the newer wx.lib.agw.aui widgets. I recommend the AGW version as it is written in pure Python and has had lots of enhancements done on it. I don't think the old wx.lib.aui widgets have had any attention in years.
See the wxPython demo for examples.
I want a detail grid kind of control in MFC, where on expanding each row of the grid an embedded dialog would appear for it (not a popup but inside the same parent control, inside which I can show other controls).
Can you please point me if there is any such existing library providing this kind of a control? Or else how to go about implementing it. I want to do it in C/C++, MFC, Win32.
Best,
Sourabh
You can try Codejock Xtreme Toolkit Pro (Link). I had the opportunity to use its Grid Control to create an excel like sheet in MFC. It was quite good for my needs.
Refer to this link, i think it has what you are looking for.
HTH