Click here to Skip to main content
15,904,926 members
Articles / Desktop Programming / MFC
Article

RGB Slider

Rate me:
Please Sign up or sign in to vote.
2.95/5 (16 votes)
15 May 2003 54.5K   1.6K   22   2
OwnerDraw Slider, Bitmap DC , Color Frame

Sample Image - My_Slider.jpg

Introduction

This is my first article and I jope you enjoy it. I wrote this with VC++.NET.

Brief description of Classes

  • _CMySlider class

    It's a class for graphical slider that has a gradient, and a little look like the photoshop RGB sliders.

  • _CColorFrame class

    This class is for previewing the color that you created.

  • CBitmapDC class

    Oh I like this one. It's one of the more useful class . I use this class to get smooth and fast drawing.

How it works

  • I created three sliders and a staticbox on my dialogbox.
  • Added three CCtrlSlider variables for the sliders and CStatic for staticbox.
  • Changed CCtrlSlider to _CMySlider and CStatic to _CColorFrame.
  • That's all :-)

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Iran (Islamic Republic of) Iran (Islamic Republic of)
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions

 
QuestionThis is a tool? Pin
Ravi Bhavnani31-Jul-04 14:00
professionalRavi Bhavnani31-Jul-04 14:00 
GeneralNot to discourage you but... Pin
Nitron16-May-03 3:01
Nitron16-May-03 3:01 
I really expected more from you. I think you've been around CP long enough to know how the story goes, so I won't bother badgering you with the obvious. There's potential here, and I think you should put some more effort into this article. Give the scenario: why did you write these classes... Give an action: How did you implement them, what hardships did you face, what resources did you tap, and how did you overcome them... Then give some resolution: How do you extend the classes to other applications, why would someone else want to use your code, what can you teach others in similiar situations so as to give back to the community that makes everyone a better developer.


Anyway, ponder on that and I hope you can afford more than the 3 minutes you spent putting this together. I cannot even bring myself to rate this article.

- Nitron


"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb

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

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