MFC Feature pack in Office 2010 style - mfc

I developed app in mFC using vs2008 and MFC Feature pack 2008. its look and feel is like 2007 office style. Now i want app look and feel like office 2010.
Will you explain me how to do it?

The easiest way is to upgrade to Visual Studio 2010, which provides a "Windows 7" style for the ribbon control. This style is supposed to simulate that native ribbon control that is used in Windows 7 applications like Paint and Wordpad. (Note that a slight modification to the wizard-generated code is currently necessary, as described here on Microsoft Connect.) Presumably, this style also looks like the one used in Office 2010, although I can't say for sure as I haven't given Microsoft all of my money yet.
Decide for yourself:
Alternatively, you could just use the native ribbon control yourself. There's a sample project here:
Windows 7 Ribbon: The Time Has Come, Your Win32 Application Will Change. But if you've already done a lot of work laying out the ribbon in VS 2008, this probably isn't a very compelling option.
Lesson: There's a hefty price to be paid for being on the bleeding edge. If this isn't exactly the same look that you're hoping to emulate, you may very well be out of luck. If your design goals amount to copying what the Office team does, you're going to be quite a busy little bee: toolbars are their absolute favorite thing to reinvent.
EDIT: Looks like you might not be completely out of luck after all. BCGSoft (the company that Microsoft bought the ribbon control from in the first place for the MFC Feature Pack) has released a library that attempts to simulate the Office 2010 experience in several different ways. Throw money at them here.

Related

Rich User Interface Application in Visual Studio

I am a noob C++ Programmer.
I want to develop GUI applications. I am using Visual Studio 2010.
Normally, Visual Studio Projects begin with the old style interface with a frame with a menu in it. But I want to build an application with more rich Graphical elements. Just like the windows 8 start screen.. or the Visual studio start page. Please teach me how to do those fancy effects.
Edit: I don't like to use flash or JavaFX Java because they need additional programs to be installed before using.
Well, basically you have not much options here. Regarding to your choice (MS Visual Studio) they are:
MFC/C++ - not convinient at all, I can say it's a small pain in the ass. But a lot of program were written exactly with a help of MFC library. It's a canonical way :)
Windows Forms/C++ - actually it's not usial C++, but C++/CLI. Not so much different, but has a few things to note. You can take a look at C++/CLI Cheat Sheet for example. Not usial, but, hey, you can use Windows Forms!
Windows Forms/C# - as for me, this combination is almost perfect. Nothing to add.
WPF/C# - even much more interesting. Any control can be modified in any way, but you have to know a lot of tricks and howtos to make all things work. In that case I highly suggest to use WPF Toolkit. Anyway, you can find a lot of cool stuff for WPF (I even made once a mini-SCADA with a bunch of UI elements related to industrial stuff (valve, pumps, etc.)). Do not forget, you can do animation as well. It is pretty easy.
Qt addon for MSVS/C++ - the last but not the least option. All UI you make in Qt Quick - GUI IDE. Also you have a greatiest slot/signal interaction model (which was improved in Qt5.0).
My choise now is definitely Qt. It's crossplatform, btw.
For C++ you can create a WinForms (Windows Forms) project.
But nowadays WPF is preferred over WinForms, and WPF is usually used from C# or VB.NET. I'm not sure if it's possible to use from C++, but if so it would have poor support. C# is pretty easy to learn if you already know C++.
If you want to create Windows Store apps in Windows 8, you can also use C++/CX, but that requires VS 2012.
So you really want to make flashy things like these, eh? Well, you can make a Windows Store app, but like previously mentioned it requires Visual Studio 2012.
Take a look at this question too: How to develop unique GUI's in Visual Studio?
You have several options of GUI from which you can choose wxWidgets, Qt, Ultimate++.
or u can use Embarcadero C++ Developer ----> actually Firemonkey is so amazing check it out
C++ Builder

Is Embarcadero C++ Builder a good choice as an IDE? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
As we are (me and people I work with) more and more frustrated while working with C++ projects 250 000+ LOC in VS2010 sp1 (the slowness of this IDE is just unbelievable), in my company we were talking about migrating our code to some different IDE. We did some research, and a strong candidate seems to be Embarcadero C++ builder 2011 XE. Any thoughts on it? Is it any good? How does it compares to VS2010 ultimate?
I've been using C++ Builder since 1.0 and I hate it with a passion. You would think after all these years, simple little annoyances would be fixed by now but they are not. Here is a list of issues I have with C++ Builder IDE.
Your layout or personality never is maintained. You create one, save it and it only applies to certain things. For example the debugger window will not maintain its position nor will the message window. If you detach the project explorer it will sometimes dissappear. Most of the time reloading your personality doesn't fix this either. You are stuck dragging your windows back into place.
The debugger will sometimes work and sometimes not work. In a debug build if you set a break point and begin stepping through code, you can hover over a variable to inspect it. Sometimes this works and sometimes it doesn't work on the exact same variable. Crazy!
Eclipse looks for code mistakes like if you forget to put a semi-colon at the end of your statement, it puts a little ? mark in the margin. C++ Builder doesn't do anything like this. It gives you a cryptic compile time error message.
Recent versions of C++ Builder use a makefile similar to VS; it's an XML mess. Eclipse works with CMake and Makefiles. I've read in places that the CMake maintainers are looking for a C++Builder generator but last I checked this doesn't exist. I do embedded and cross compiling so sometimes my C++ Builder code is copied to my embedded development environment or shared with it and I wind up maintaining two build environments.
Not really an IDE but C++Builder does not take advantage of multiple CPUs to compile code. There is, however, a 3rd party tool you can spend more money on to get this. It's called TwineCompile (http://www.jomitech.com/twine.php). With Eclipse, they call out to whatever compiler you're using (gcc, etc...) and those compilers and make support -j option.
C++Builder comes with a limited version of AQTime which is a dynamic code profiler. Spend more and you get the more advanced version. Eclipse supports many dynamic and static code analysis (which also cost $$) but at least the plugins are there. We use Klockworx.
C++ Builder has no support, that I'm aware of, for external source control like GIT. Eclipse does. C++ Builder comes with subversion, I think, built-in. If it supports GIT, I could never get it to work. It tells me it doesn't understand the URL scheme when I give it a git path.
Certain template code I write causes the compiler to segfault and have to completely restart the IDE. This is nuts to me. You have a compiler that is 10+ years old and it's still segfaulting. I have a piece of C++ template code that when I take it to my work computer running exact same version of C++ Builder, it compiles OK, but on my home machine it segfaults. I'm absolutely sure there are no adverse factors at play like viruses, etc...
While compiling a large project that may take a long time, you are unable to browse code with the IDE. Sometimes you may see a compiler warning scroll by and you have to either wait for the compile job to complete to inspect the mentioned line or use an alternate means to open the file.
C++ Builder IDE has a concept of a Project Group with sub projects that are more/less self contained. The Project Group has no concept of a project group include/link path like the sub-projects have. Sub-projects have a base, debug, release paths where debug and release can inherit or block from the base but you don't have this at the project group level. The IDE has global settings which can be inherited but it's for everything you do in the IDE. So there is no way to modify for a given project group, just the include/linker paths for a set of sub-projects. I just think they could have done a better job with this.
C++ Builder's Build output is not color coded to, for example, show errors in red and warnings in some other color. Everything is black and white. VC and Eclipse color code and give option to change colors for various warnings and errors. The output tab in C++ Builder is same way. On big projects, it's very difficult to investigate compiler warnings with the other noise. In C++ Builder's IDE you can select level of warnings but this only affects output in the Output tab and you still get other stupid noise like letting me know its deleting linker state files "CleanLinkerStateFiles."
Unless you're doing Windows desktop GUI development, stay away from Embarcadero/C++ Builder. I started using C++ Builder version 1 back in the Borland days and have a few large projects that are heavily invested in the VCL so I'm stuck with it for those projects but all my new projects, I've been using Eclipse.
On a positive note about C++ Builder, the VCL is quite nice. It's not multi-threaded but it's nice for creating a desktop GUI app really quick. I think it's much faster to get a C++ based GUI app up in CBuilder than it is in VS. And there appears to be a ton of free and paid GUI components for CBuilder; again with a C++ focus. I know C# + VS has a wealth of GUI controls.
UPDATE:
I just ran into a problem today that is same as the one mentioned in this forum:
http://qc.embarcadero.com/wc/qcmain.aspx?d=57631
[ILINK32 Warning] Warning: Error detected (ILI4536)
Make up your mind. Is it a warning or a god dam error?
Scroll all the way to the end where you find individuals modifying ILINK32.EXE to get it working again. As of this morning, our builds stop working. We're dead in the water as we scramble to understand and find out what to do about this.
Is this the kind of compiler/IDE you want to depend on? Again, this product has been around for more than a decade and it still has issues like this. I find this completely unacceptable. Crap product from a company that doesn't give a shit.
Not actually an answer, but I'll just leave it here:
It costs money (yes, VS too, but you already own that, don't you?)
It will be not too easy to migrate a big enough project to new IDE (and compiler), not to say about the people you work with and their habits (I would just quit probably).
There's a new compiler too, with its brand bugs and caveats to learn about. And it's much less widely used than VC++. However, it's based on Clang, which should support standards better than VC++, and be easier to port existing C++ code to.
The difficulty of migrating hugely depends on the nature of your project (is it GUI based, how deeply does it rely on MS VC++ being the compiler?)
There is nothing positive about Embarcadero XE, neither their aging IDE neither their aging compiler. Only use it if you're bound to it (legacy software) or if you want to do Delphi.
For C++, do yourself a favor and join 21st century : stick with something more powerful, versatile and modern such as VC++ or Qt.
This question is really a matter of personal opinion.
I personally HATE Visual Studio with a passion, I avoid it like the plague. My exposure to Eclipse has been limited to Java, but even then I've had a hard time working with it.
I have been using C++Builder for 15 years, since v3.0 all the way up to the latest XE6. Yes, it has quirks and limitations, but I still find it the easiest IDE for me to work with and be productive with, once you know how to work with (or around) them. Maybe my experience with it is hindering my ability to work with other IDEs, but so be it. I still prefer C++Builder over any other. But I only use it for Windows development (the VCL is very mature and robust), I don't do cross-platform development with it yet (FireMonkey still has a ways to go to evolve and mature). And I do use plenty of open-source projects with it. Yes, sometimes I have to tweak their projects and/or code to make them compile, but that it usually a one-time deal and then they work fine.
I'd suggest Eclipse.
As an IDE, it takes a little while to get used too, but it is well
worth the effort.
It's available for Mac OS, Linux and Windows.
You need to have Java installed on your computer, but that's
really a non - issue.
It supports Cygwin, MinGW, and the MicrosoftVisual C++ toolchains. The build in CDT Builder is pretty good too.
You can use it to develop for languages other than C++ (Java , JavaScript, PHP ..)
You can extend it's functionality by installing plugins
IT'S FREE!
Did I mention that it has a built in Web Browser ? Really useful for referring to online documentation, while coding.
1.
We have a solution over 1M LOC and VS2010 handles it ok. We especially like /MP switch for compiling on all available CPU cores.
You did not specify your hardware. If you don't yet run on at least i7-2600 + fast SSD, I suggest trying hardware upgrade first.
2.
I used to use Borland tools a lot in the past. Delphi was rather stable; C++ Builder was much more buggy. Couple of years ago I helped to upgrade old Delphi projects to newer Delphi IDE with some service packs installed. And it had bugs even in the basic File IO APIs which have worked since Turbo Pascal. We had to downgrade to a previous version. I expect that quality of C++ Builder won't be much better than of VS2010.
3.
You did not specify what exactly is slow. You may want to convert some projects into components compiled separately. Also make sure you use PCH.
Also it worth investigating if you abuse C++ inclusion model by including a lot of unneeded header files in each and every unit. If, after preprocessing, Intellisense and compiler have to deal with huge amount of code, no IDE can help.
I have not used Visual Studio 2010 Ultimate for C++, rather C# and C# web services development. That being said, as a test between VS 2010 Ultimate and C++Builder XE, I have created a simple VS C++ Windows Forms application to click a button and show "Hello World" through an event handler. Getting the button onto the VS Window Designer is okay, as long as you remember to access View | Toolbox. If not, it will take some time to track down where the visual components are hanging out.
For reasons that do not make any language sense, the button click event handler has a signature that looks like:
System::Void button1_Click(System::Object^ sender, System::EventArgs^ e) {
}
and it goes to the header file as one would expect. The ^ symbol makes little sense. Does using it tie into the CLI/CLR better? I expected a * to indicate a pointer.
After using the default Form1 (only header file created) and subsequently adding a new windows form, I finally obtained the respective cpp file. Maybe the C++ Windows Form Wizard has a bug. Who knows? Anyhow, when adding the button click event by double clicking the button in the designer, the cpp does not obtain the method in either cpp form I tested. Maybe this is normal, I do not know. The end result of this is that after trying to use the MessageBox function within the cpp, it only caused compilation errors. I am sure there is yet another header file that has to be in the include path. I spent no time tracking this down. Trying to set a label component text property caused compilation errors too. About 20 minutes later, I went to C++Builder XE3 in frustration.
In C++Builder, I have tested VCL Forms, FireMonkey Desktop, and FireMonkey Metropolis application creation from the project wizard. Sure enough, I have three different applications saying, "Hello World," in about three minutes total, all calling C++Builder's built in global shortcut function called ShowMessage("insert message here"). The timing could have been slightly different as I did not time it with a stop watch. It took longer to save files with meaningful names than the code itself: one line of typing in the respective click event body in each cpp (not the header).
The other main daily use gotcha with VS, for those of us who love the Brief key map, is that VS is highly challenging to configure into Brief. When doing heavy development in C#, I use C++Builder's editor in Brief mode, saving files as often as I want. VS does correctly detect file updates as you click back to the VS IDE.
On the slowness mentioned by the OP above, I suggest also looking very closely at the hardware platform relative to running Visual Studio. I have noticed that if the .Net framework is out of date, VS will be slow within the IDE. It does not seem to matter which language the project is in either. I use Visual Studio 2010 Ultimate on Parallels with Windows XP Pro, with 2 virtual cores. Generally, VS responds normally within the IDE. While using it, I am NOT thinking, "VS is soooo slow."
Regarding migrating a quarter million lines to C++Builder from VS, I am not sure whether VS event handlers will convert by some wizard or other migration tool. The ^ symbol, if consistently used in all event handlers, may not be a big deal for a regular expression conversion that is custom written. If the project is very thin on the user interface layer and heavy in business rules and data, converting to C++Builder should be relatively easy. I would expect some new coding for the new user interface click events passing the user interaction into the other layers. For prototyping, using data aware components are likely your best bet. In normal application running, expect to have the business rules layer use the STL and built in C++Builder data structures (even the AnsiString c_str() method) to interact with non data aware components. The performance and user experience will likely improve.
Start Edit
A big knock on C++Builder XE3 (note this is two releases behind the current one of five) is that the 64-bit Windows support is only for console applications. The knock is more from not being frequently broadcast on how to use the Add Platform sub-menu that appears when right clicking the mouse over the Target Platforms choice in the Project tree view. This quick method to add more platforms to a project after it may first be targeting 32-bit Windows is virtually painless. A new sub-dialog appears after clicking the sole sub-menu choice and a drop down box appears to select the new operating system and respective 32-bit or 64-bit versions. In my opinion, Embarcadero is not demonstrating often enough how simple it is to add other target platforms. So, to ease all developer's pain if this is not known in advance, I have found three web pages on the Embarcadero site. The first one has pretty pictures of creating a FireMonkey desktop application. Step 5 has the screen capture of the Target Platforms | Add Platform sub-menu choice for adding the Mac OS X platform. It is here titled Creating Your First FireMonkey Application for Desktop Platforms (C++): http://docwiki.embarcadero.com/RADStudio/XE2/en/Creating_Your_First_FireMonkey_Application_for_Desktop_Platforms_%28C%2B%2B%29
The more terse and no picture procedure is here titled Steps in Creating Cross-Platform Applications:
http://docwiki.embarcadero.com/RADStudio/XE2/en/Steps_in_Creating_Cross-Platform_Applications
The Windows centric procedure and a small screen capture is here titled 64-bit Cross-Platform Application Development for Windows:
http://docwiki.embarcadero.com/RADStudio/XE3/en/64-bit_Cross-Platform_Application_Development_for_Windows
I have found on an Embarcadero forum post that an upgrade to the Update 1 XE3 release from the original XE3 release has a Target Platform selection issue. There can be an internal path setting or two that is incorrect, and possibly having to change an original XE3 project file (.cbproj) to enable Win64. Apparently the original release project file has this set to false.
XE5 (note version five as of December 2013) is supposed to have 64-bit Windows support for both console and forms applications (e.g. VCL, FireMonkey Desktop, FireMonkey Metropolis), OS X, iOS (Android coming sometime soon). For the complete list, review the C++Builder feature matrix pdf for all of the XE5 details:
http://www.embarcadero.com/products/cbuilder/cbuilder-feature-matrix.pdf
Since the XE3 Update 1 has been shown to resolve Target Platform selection issues, when compared to the original XE3, there should not be any weird behaviors. I have also come across an Embarcadero post that states from a TeamB member that for mobile applications, the Target Platform choices are filtered such that mixing a desktop platform project with a mobile one is not allowed. So, if one wanted to try creating a desktop application and then with a mouse click force it into an iPhone, some other development tool will have to be used. C++Builder and/or Delphi will not attempt to squeeze desktop components onto a mobile device. You have to start with a mobile application project. Here is the forum link:
https://forums.embarcadero.com/thread.jspa?threadID=96371
(End Edit)
If curious about my overall background, I have used C++Builder since version one, Visual Studio .NET (C# 1.0) and Visual Studio 2010 Ultimate. It seems like Visual Studio concentrates on C# more than any other language. There are eighteen C# projects and fifteen C++ projects when selecting File | New Project. To reach the Visual Studio C++ project area, make sure to reach it by opening the "Other Languages" sub-tree.
In recent Internet posts between Visual Studio latest and greatest and C++Builder latest and greatest, purchase prices vary in the thousands of dollars. Even if never ever having an installation to upgrade either tool, C++Builder remains a bargain compared to Visual Studio. Please conduct thorough research before spending your hard earned cash. Hopefully both tools have 30-day trial installations to compare side by side, as your mileage may vary.

Gauge Control for C++ Application

Can anyone suggest good Gauge controls to use in application using C++.
The Gauges will be used in application monitoring Temperature, Pressure or Flow devices.
Please let me know about any commercial or free libraries that works on pure C++, without any dependency on .Net framework
Thanks,
For wxWidgets there are the (free) wxIndustrial controls. Update 11/2015: last updated in 2007, no downloads but source code still available here
Also you'll find more controls at wxCode.
I suggest you to give a look to National Instrument's Measurement Studio.
I am adding the link: NI-Measurement Studio
The title might be a bit confusing since it says: NI Measurement Studio
for Unmanaged Visual C++ .NET but Measurement Studio 2009 (and previous) also has C++ libraries that do not depend upon the .NET framework. They are MFC controls.
In that same page, you can actually clic the link to try it and decide for yourself.
QWT is an extension to the Qt GUI library. You can use this library to create Dials, Compasses, Knobs, Wheels, Sliders, Thermos etc.
Also check QGauge
You may try BeauGauge Instrumentation Suite.
Preview of Gauges
http://www.beaugauge.com/en/gallery.html
Demo Download
http://www.beaugauge.com/en/downloads.html
Here you go. It is completely free but for commercial use you should probably pay license fee.
http://www.mitov.com/html/instrumentlab.html
You may try ChartFX Gauges COM: http://www.softwarefx.com/sfxComProducts/cfxForCom/

Will the Scenic Ribbon ever be supported by the MFC Feature Pack?

My team has spent a long time developing a nice UI using the ribbon included in the VS2008 MFC Feature Pack.
Now that Windows 7 is out and the look and feel of the ribbon has changed, my application looks out of date already, and it hasn't even been released yet :/
I want the look and feel of the Windows 7 ribbon ("scenic ribbon") ideally without changing anything - does anyone know whether there will be an update to the feature pack which will solve this?
I can't move to using the Windows 7 SDK ribbon, because I need to support XP, and the 7 SDK only supports 7 and Vista.
The only alternative I can think of is to go for a 3rd party library such as BCGControlBar Pro or Prof-UIS Elegant Ribbon, both of which I don't mind paying for but it's the amount of rework that's the issue (presumably the BCG one would be the easiest to migrate to, as the MFC Feature Pack ribbon is based on that one).
This blog shows that in VS2010 the MFC ribbon will have a "Windows 7" style.
So I guess I just need to wait for VS2010. Result!

Whats the best Ribbon UI control to retro fit to a legacy MFC application build with VC2005?

What experience have you had with introducing a Ribbon style control to legacy MFC applications?
I know it exists in the new VC2008 Feature Pack, but changing compilers from VC2005 is a big deal for our source base and integration to our environment, Intel FORTRAN, ClearCase, many 3rd libraries.
There are quiet a few different commerical implementations, most focusing on C#/VB .NET, and only a few for native C++ MFC.
I have read all the usual reviews found by Google most are quiet old now, so I am interested to here from people who have actually done it, been through the pain barrier, released a legacy application with VC2005 and a Ribbon UI.
We currently use a very old version of Stingray Objective Toolkit to provide our MFC extensions like customizable toolbars and docking windows etc.
Any one used Prof-UIS, compared to the other commercial ones its relatively cheap, unlimited developer licensing is a 10th the cost of the others.
Are there any free, open source or L-GPL'd ones available?
In my projects I'm using the MFC Feature Pack in Visual Studio 2008, which is based on code from BCGSoft. Their BCGControlBar Library Professional Edition includes a ribbon control and is compatible with Visual Studio 2005.
I'm not aware of any open source ribbon control libraries for C++, though.
We use Codejock. It's not cheap, but I guess I've come to find that good controls usually are :-). They are fairly responsive in the tech support department (although we haven't had need to use that recently). We are buidling a whole suite of tools using these controls and have always had what we've needed, including the ability build the office 2007 style ribbon.
Please be aware that you need a license from Microsoft to use the ribbon control in your application. They give it for free as long as you don't write a software to compete with Word or other Office software.
Take a look at this link: Office UI Licensing.
People are generally not happy with Microsoft for this: The evil of the Office UI ribbon license.
We implemented a ribbon in our app due to pressure to have the latest/flashiest looking UI. It looks good, but the usability isn't good compared to using a plain toolbar!
To adhere to Microsoft's License to use the ribbon, you have to stick to their guidlines on how it should be used. Eg.. only the user can change ribbon tabs, you can't do it programatically except when switching to a context tab. All these limitations mean that the ribbon only applies to applications that are definitely document-centric. If you're app isn't document-centric, don't think you can just drop a ribbon in to replace a menu/toolbar driven system without giving it a lot of thought about how everything is going to fit together.