For a new project, I'm writing an administrative tool as a client software.
So far, I've only written some small winforms application with a 'old-lookin' GUI.
I'm thinking of something fresh, new looking like ribbon based design.
The questions that come into my mind are:
1) Should I prefer WPF over Winforms for a ribbon based GUI(though I've never touched WPF before)
2) Are there any recommendations for free ribbon controls? I've found out that Microsoft seems to have this ribbon license, but I still don't get it. Do they offer a full functional ribbon based control? If yes, Winforms or WPF?
Visit http://fluent.codeplex.com/ to download a free ribbon for WPF. This ribbon has the style of the Office 2010 ribbon, and I've already used it in one of my apps. The download also has a lot of examples on how to implement the ribbon into a WPF application.
As far as switching from WinForms to WPF, yes it's a big learning curve, but at some point you should take the dive and start learning it. You'll be glad you did.
Related
I am very new to Windows form based application. I have Visual studio 2012 and want to create a windows application.
This question might be asked before but I was not able to find any clear answer, so I decided to post the question here..
I want to know that if there is a way to create a master form (or a kind of template) for my application having common controls and rest of the forms can inherit that, likewise we do in web-applications.
I found somewhere that instead of going with Windows Forms application, I should go with WPF application, if that is the case can somebody point me to a good article where I can find some info about it....
I really advise you to work with WPF, windows forms is dead since years. WPF is very flexible and you can do far more things than windows forms.
Here is how to implement Master-Page like behavior using WPF: Link.
Here are some WPF tutorial to start your journey:
http://www.wpftutorial.net/
http://www.tutorialspoint.com/wpf/
Learning WPF and XAML is great as it is very similar to most new technologies like Android (layouts), Xamarin (Forms), etc... So it is good technology to learn.
I am new to Creating WPF GUI Applications.
I am a Mid Level Programmer. I dont have any idea or knowledge about the Graphics Development.
I would like to know how do I use the UI Elements designed in Photoshop in my WPF Application.
Eg: I would like to replace the default textbox or the button in WPF with the button or textbox designed in Adobe Photoshop.
Last Information:
I am using Expression Blend 4.
Any Help Would Be Appreciated, Thanks
Starting with WPF
I personally work with a combination of Microsoft Visual Studio (environment) and Microsoft Expression Blend (elements editing).
Blend is a WYSIWYG front-end for designing XAML-based interfaces for WPF and Silverlight applications, and it's good for templates, visual states, and animation.
Editing Templates
If you are working with templates, a nice tool is WPF Theme Editor by DevExpress. It integrates with Blend, and the tree browser and template hierarchy are very useful for locating styles.
One thing you'll always find helpful is access to the actual structural templates for the elements. I usually find myself visiting the DevExpress WPF Controls website, which has a very comprehensive list of libraries and controls.
The Demo Center for DevExpress is also a great downloadable app for extracting and editing templates. I find it particularly useful with complex elements like charts (not included in Blend), where you can toggle the visibility of elements and then move the code to your dev space.
Creating Graphics
For working with graphics themselves, I found Microsoft Expression Design to be quite good for drawing and exporting vectors into png, WPF or Silverlight formats. It has a nice simple set of tools, and you can import elements from vector. Also, version 4 is free.
Testing
I just discovered this nice tool for testing live called Snoop. It's open source, and it allows you to spy/browse the visual tree of a running WPF application (without the need for a debugger), and change properties live.
For all of these you will probably need at least a basic knowledge of how to write/read WPF. I personally use all of the previous and write custom styles for custom elements.
Does anyone know some good guides on making Ribbons that actually look good like the one in Office 2010?
Preferably non-Microsoft guides since I've read several already and wasn't too thrilled with the results or ease. Some things in particular that I've never seen replicated are the semi-transparent deselected tab headings, good high DPI scaling, and smooth window resizing, etc. Little things like that make or break the program!
I'm using the Windows Ribbon for WPF (October 2010) / Windows 7 / .NET 4
Here are some options to look into:
DevExpress Ribbon
CodeProject Ribbon Wrapper
Ribbon API
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
i am trying to automate the gui in c# .Is this same as browser automation .how can i start ui automation
If you are using WPF, Microsoft has a very detailed UI Automation library.
http://msdn.microsoft.com/en-us/library/ms747327.aspx
I had a look around but I couldn't find an equivalent for WinForms.
You can use Microsoft's UI Automation library, but it isn't much fun. "White" is a better alternative... see: http://www.codeplex.com/white
EDIT:
New url to "White" project as it was moved to TestStack on GitHub: https://github.com/TestStack/White
WiPFlash is good, easy to use, open source wrapper on top of Microsofts UI automation library. But they're limited by the underlying Microsoft Automation structure.
FlaUI is a good alternative to "White" library, based on native UI Automation libraries from Microsoft.
9 Years later Appium is a good option, also a reference side from Microsoft, since CodedUI is obsolet.
Microsoft build the WinAppDriver for Appium. You can also just use the WinAppDriver to test your gui. you need Appium, just if you want to do contionouos integration.
Differences:
Teststack.White is an efficient Testframework. It doens´t need as much time as WinAppDriver (Appium) to go through the tests and its very easy to implement in your testproject. But the support isn´t as good as WinAppDriver. Teststack.White as example still doesn´t support UWP (maybe no one want to develope with UWP :P ). On the other side, you need Windows 10 or Windows Server 2016 to work with the WinAppDriver. Both have an easy implementation of tests, but you need to set some JSON-Values, to get a http-connection with the WinAppDriver.
At least the WinAppDriver with Appium has much more possibilities, but TestStack.White is easy implemented.
Be careful if your GUI is using any 3rd party Windows controls, like Devexpress controls, or Telerik controls.
MS UI Automation would have difficulties to locate those fancy grids, lovely menus and pretty icons.
Talking about TestStack.White, it's using MS UI Automation as the cornerstone, so it would face the same problem locating detailed GUI elements.
You will know when you need to manipulate the grid by row but UI Automation or TestStack.White could furthest only return you the table object, then you will find your R&D efforts before the project starts were all wasted. That's how I learned that lesson, but now I am the expert.
http://msdn.microsoft.com/en-us/library/ms747327.aspx like Alastair Pitts pointed out can be used. From my knowledge it should be good for any automation tasks - as long as Windows recognizes the control your application uses as standard controls or controls that have automation support. Which should be the case for just about all major control vendors. And defnitely MFC, Win32, WinForms and probably WPF and Silverlight as well.
You can get an idea of what you are up to (against) by firing up Spy++ and having a look at what it displays.
You might also want to listen to the other ideas, using Tools like White (opensource) or Rannorex (which is commercial).
I'm using WINFORMS not WPF.
I just know basic c# .net gui programming. I donot want the traditional windows look. I want to have my own custom look (eg. gtalk, antivirus softwares, media players, google chrome).
Actually I'm inspired by google's PICASA software. Its awesome. I want to do something like that.How can I do that? If there is something I should learn please point me.
Also I may have to write my own custom controls (like modified tree view etc..) I guess. Please give some good learning resources.
This article describes how to draw custom windows. The author also shows how to draw non-rectangular windows.
If you could use WPF instead of Windows Forms, this is a good article about customizing window drawing:
http://www.codeguru.com/csharp/.net/net_wpf/article.php/c16379/
There is also a question with some good answers here on SO:
Creating custom forms in WPF?
Update:
I think that skinning and custom drawing is fun to do from a programmers perspective, but I also think that there is almost no benefit for the user.
The creators of the platform you are developing for might have put a lot of effort into the design of their windowing toolkits.
If you just want to change some visual aspects of your application you also should take into account that you might miss some important other aspects of UI design:
consistency
accessibility
aesthetics (if you are overdoing
effects, gradients, ...)
internationalization
...
As you are developing for Windows, you also lose the skinning ability of the OS itself. And I think that some of the skins that come with newer versions of Windows are pretty good.
You can try any of the following:
telerik
Syncfusion
(source: componentsource.co.jp)
Or other components.
They do make your UI pretty.
Edit: if you want to study how they do it, you can buy the source code-- along with documentation and understand from there.
There are some commercial control libraries available.
I can recommend the Krypton Suite. It consists of the free Krypton Toolkit (which contains a lot of skinnable controls) and other non-free controls (Navigator, Ribbon, Docking, Workspace). It has some built-in palettes and renderers that allow you to make your UI look like Office 2010, Office 2007, Office 2003, ...
You want to look for +winforms +skinning. I haven't tried these, but the first hits don't look bad. Most decent skinning tools will be paid for.
From what you said, you want to develop your own custom controls. You have some frameworks for this like Qt which can use Direct3D for hardware accelerated graphics. It also have a Visual Studio plugin. There is a free LGPL version and a commercial version of it.
I remembered about Qt because you mentioned Picasa and as far as I remember, I heard the Picasa UI has been written through Qt.
You can try using "SetWindowRgn(..)" to set an arbitrary region for your window. This may range from giving a rounded rectangle shape to giving a weird looking shape to the form!
Check this out: Link.
There is another option if you are working in Vista(aero enabled), ie you can check out DwmExtendFrameIntoClientArea(..) function here: link text
You can set the form's border style to 'none' and go on to create your custom form! You then might have to create custom buttons to carry out tasks like close, minimise, maximise etc. You might even need to write code for drag and drop events..
For the background, you might need to have a look at the gradient fills to give a great effect, otherwise you can use great looking pictures as Background..! But the latter option isnt good unless you have really good pic.