Click here to Skip to main content
11,429,382 members (69,874 online)
Click here to Skip to main content

The new RibbonForm, RibbonRoundButton, and FastMenu

, 3 Jun 2007 CPOL
Rate this:
Please Sign up or sign in to vote.
A free version of RibbonForm, RibbonRoundButton, and RibbonFastMenu.

Screenshot - RibbonTest.png

Introduction

In this article, I present the RibbonForm, RibbonRoundButton, and RibbonFastMenu as a release version. I present RibbonContextMenu as a preview version because I have to improve some parameters to work with it well.

The Controls

RibbonForm 1.0

Screenshot - RibbonForm.png

The RibbonForm was a bit difficult to design due to it being a modeless window, and I had to implement all the resizing and window moving by myself. Also, I had to implement a HSB method to change colors.

Properties

The RibbonForm has these properties:

  • CompB: To change the Brightness of the Form with a value that I recommend to get from the RibbonFormSample (see screenshot above).
  • CompS: To change the Saturation of the Form, the same as above.
  • CompH: To change the Hue of the Form, the same as above.
  • TextSection: It's the subtitle of the Form with the harmony color.

How to use

In a new Windows application, add an existing item from the Solution Explorer, and choose the RibbonForm.cs (it adds the other files needed). Now, in the Form1.cs code, change to this:

using RibbonStyle; //To add the NameSpace

namespace RibbonTest
{
    public partial class Form1 : RibbonForm //To inherit from RibbonForm
    {
        public Form1()
        {
            InitializeComponent();
        }
    }
} 

RibbonRoundButton 1.0

Screenshot - RibbonRound.png

It was really hard to design a vectorial round button with fading, but I think it finished well.

Properties

The RibbonRoundButton has these properties:

  • ColorBase, ColorOn, ColorPress: The typical colors.
  • ColorStroke: Is the border of the button.
  • ImgOffset: You can move the image from topleft to rightdown.
  • ImgScale: You can scale the image from 1 to 100.

How to use

You can choose two options: as other buttons, you can add the DLL in Class_RibbonRoundButton, or you can add an existing item in the Solution Explorer and choose RibbonRoundButton.cs, then recompile and add the button to the Form.

RibbonFastMenu 1.0

It's the form that appears when you click on the MenuButton on the top-left. This Form has the typical app options.

I have to implement a SetHSB() method to change the colors, but it is functional.

How to use

In a Windows application, choose Add Existing Item, and select the RibbonFastMenu.cs. I recommend adding all the existing resources from the RibbonTest app to have all the images, and then you will have a Form like in the first image of the article.

Comments

I'm designing a better way to use the RibbonContextMenu because I think it's a bit difficult to use, but please be patient till I finish it.

Keep in mind

  • I have to add the SetHSB() method to the FastMenu.
  • Make a better way to implement the FastMenu.
  • Make a stable version of the RibbonContextMenu.

History

  • June 2007 - RibbonForm 1.0, RibbonFastMenu 1.0, RibbonRoundButton 1.0.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Juan Pablo G.C.
Software Developer Expediteapps
Spain Spain
I'm Electronic Engineer, I did my end degree project at Astrophysical Institute and Tech Institute. I'm HP Procurve AIS and ASE ,Microsoft 3.5 MCTS
I live in Canary Islands ,developing customized solutions

Deeply involved in Xamarin Forms LOB (including Azure Cloud with offline support, custom controls, dependencies) projects, WP8.1 & W10 projects, WPF modern styled projects. Portable libraries like portablePDF, portableOneDrive, portableReports and portablePrinting (using Google Printing API).


Web and apps showcase at:
Expediteapps


Take a look to my blog
Blog
Follow on   Twitter

Comments and Discussions

 
GeneralMy vote of 2 Pin
i0024-Jun-14 2:47
professional i0024-Jun-14 2:47 
GeneralRe: My vote of 2 Pin
Juan Pablo G.C.11-Jul-14 4:42
memberJuan Pablo G.C.11-Jul-14 4:42 
SuggestionForm Resize/Positioning Fix (modification) Pin
Someguydude30-Jun-12 6:59
memberSomeguydude30-Jun-12 6:59 
GeneralTidy up the code == Fix CPU utilisation Pin
seeblunt1-Sep-09 14:53
memberseeblunt1-Sep-09 14:53 
GeneralCPU 100% Pin
naami_siq23-Nov-08 0:00
membernaami_siq23-Nov-08 0:00 
GeneralRe: CPU 100% Pin
kapil bhavsar26-Jun-09 2:37
memberkapil bhavsar26-Jun-09 2:37 
GeneralCPU 100% Pin
naami_siq22-Nov-08 23:57
membernaami_siq22-Nov-08 23:57 
GeneralA suggestion to improve the form Pin
javar9-Sep-08 21:34
memberjavar9-Sep-08 21:34 
GeneralFew problems in your implementation Pin
HawVie15-Apr-08 1:06
memberHawVie15-Apr-08 1:06 
GeneralRe: Few problems in your implementation Pin
Mark Rice11-Aug-08 9:26
memberMark Rice11-Aug-08 9:26 
GeneralGenerating code for alt colour Pin
Derek Bartram29-Jan-08 21:20
memberDerek Bartram29-Jan-08 21:20 
GeneralComments Pin
derek_bartram29-Jan-08 14:52
memberderek_bartram29-Jan-08 14:52 
GeneralFormBorder style Pin
Crusty Applesniffer2-Jan-08 6:51
memberCrusty Applesniffer2-Jan-08 6:51 
GeneralBug in RibbonColor [modified] Pin
The_Mega_ZZTer17-Aug-07 9:19
memberThe_Mega_ZZTer17-Aug-07 9:19 
GeneralRe: Bug in RibbonColor Pin
flash.tato27-Dec-07 5:48
memberflash.tato27-Dec-07 5:48 
General100% cpu power Pin
Roey C4-Aug-07 8:19
memberRoey C4-Aug-07 8:19 
Questionhow would you do this with other components Pin
MartyK20073-Aug-07 4:00
memberMartyK20073-Aug-07 4:00 
NewsGreat job! But I have s small question: Pin
Le.Wang1-Aug-07 4:01
memberLe.Wang1-Aug-07 4:01 
GeneralGREAT JOB! Pin
Sniper16720-Jul-07 11:33
memberSniper16720-Jul-07 11:33 
GeneralRe: GREAT JOB! Pin
Juan Pablo G.C.21-Jul-07 23:54
memberJuan Pablo G.C.21-Jul-07 23:54 
QuestionIs it just me or is this unusable right now? Pin
eeMarcoK28-Jun-07 22:18
membereeMarcoK28-Jun-07 22:18 
GeneralProblem in Resize with 2 monitors... Pin
PakT25-Jun-07 7:08
memberPakT25-Jun-07 7:08 
GeneralThanks! Pin
hoana200714-Jun-07 1:42
memberhoana200714-Jun-07 1:42 
GeneralDisposing of graphics objects Pin
razzielx7-Jun-07 10:41
memberrazzielx7-Jun-07 10:41 
GeneralGreat job Pin
raymond.chen20085-Jun-07 16:33
memberraymond.chen20085-Jun-07 16:33 
Generalgood job but.... Pin
Sacha Barber5-Jun-07 12:40
memberSacha Barber5-Jun-07 12:40 
GeneralRe: good job but.... Pin
Juan Pablo G.C.5-Jun-07 21:11
memberJuan Pablo G.C.5-Jun-07 21:11 
GeneralRe: good job but.... Pin
Sacha Barber5-Jun-07 22:14
memberSacha Barber5-Jun-07 22:14 
GeneralRe: good job but.... Pin
Paul Selormey12-Jun-07 18:06
memberPaul Selormey12-Jun-07 18:06 
JokeRe: good job but.... Pin
Sacha Barber15-Jun-07 2:19
memberSacha Barber15-Jun-07 2:19 
GeneralRe: good job but.... Pin
Paul Selormey15-Jun-07 4:23
memberPaul Selormey15-Jun-07 4:23 
GeneralRe: good job but.... Pin
Sacha Barber15-Jun-07 6:05
memberSacha Barber15-Jun-07 6:05 
GeneralRe: good job but.... Pin
Paul Selormey15-Jun-07 18:44
memberPaul Selormey15-Jun-07 18:44 
GeneralRe: good job but.... Pin
Sacha Barber17-Jun-07 22:19
memberSacha Barber17-Jun-07 22:19 
GeneralRe: good job but.... Pin
Paul Selormey17-Jun-07 23:40
memberPaul Selormey17-Jun-07 23:40 
GeneralRe: good job but.... Pin
Sacha Barber18-Jun-07 1:04
memberSacha Barber18-Jun-07 1:04 
GeneralRe: good job but.... [modified] Pin
Paul Selormey18-Jun-07 1:40
memberPaul Selormey18-Jun-07 1:40 
GeneralRe: good job but.... Pin
Sacha Barber18-Jun-07 2:23
memberSacha Barber18-Jun-07 2:23 
GeneralRe: good job but.... Pin
Paul Selormey18-Jun-07 4:10
memberPaul Selormey18-Jun-07 4:10 
GeneralRe: good job but.... Pin
Sacha Barber18-Jun-07 22:25
memberSacha Barber18-Jun-07 22:25 
GeneralRe: good job but.... Pin
Sacha Barber5-Jun-07 22:21
memberSacha Barber5-Jun-07 22:21 
GeneralRe: good job but.... Pin
Juan Pablo G.C.6-Jun-07 7:19
memberJuan Pablo G.C.6-Jun-07 7:19 
GeneralRe: good job but.... [modified] Pin
Sacha Barber6-Jun-07 22:28
memberSacha Barber6-Jun-07 22:28 
GeneralPoor Chris Pin
Muammar©4-Jun-07 21:43
memberMuammar©4-Jun-07 21:43 
GeneralGreat component! Pin
nick_journals4-Jun-07 21:32
membernick_journals4-Jun-07 21:32 
GeneralRe: Great component! Pin
Juan Pablo G.C.4-Jun-07 21:37
memberJuan Pablo G.C.4-Jun-07 21:37 
QuestionRe: Great component! Pin
nick_journals4-Jun-07 21:58
membernick_journals4-Jun-07 21:58 
AnswerRe: Great component! Pin
tec-goblin5-Jun-07 0:49
membertec-goblin5-Jun-07 0:49 
GeneralRe: Great component! Pin
Clevedon_Peanut12-Jun-07 5:55
memberClevedon_Peanut12-Jun-07 5:55 
GeneralPor favor, como puedo contactar contigo Pin
Fco. Javier Marin4-Jun-07 13:57
memberFco. Javier Marin4-Jun-07 13:57 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.150428.2 | Last Updated 3 Jun 2007
Article Copyright 2007 by Juan Pablo G.C.
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid