Visual Studio Add-RGB Macro Creator

Environment: VC6 SP5, W2K SP3

This addin supports one command: ColorSelectorCommand. The addin shows a standard ColorSelect dialog and forms text that looks like an RGB-macro string (RGB(100, 120, 130)). Before the dialog is shown, the addin checks the current selection. If the selection starts with "RGB," the current color in the dialog will be set to those RGB values.

Gert-Jan de Vos has decided to add some features:

  • The selector now provides a choice for RGB(), hex, or HTML format color output—(RGB(255, 128, 64), 0x4080FF, #FF8040)
  • It recognises any of the supported formats in the source.
  • It recognises input if the cursor is anywhere in the color text.
  • It adds a toolbar button.

The addin became much better after its additions. I only have changed a little RGB-processing and have added a check on hex-values. Now the addin also can processes strings of the RGB(0xFF, 0x80, 0x40) kind.

Also, I have added a function "pipette" to define the color of a point in any place on the screen.

Note: For definition of color outside Windows' Visual Studio, it is necessary to hold down the left mouse button.

Downloads

Download addin - 19 Kb
Download source - 28 Kb


Comments

  • addauto.h' isn't in the project

    Posted by alost on 01/23/2008 04:49am

    Loading snd building the project give the message: Compiling... StdAfx.cpp WINVER not defined. Defaulting to 0x0600 (Windows Vista) c:\avo\colorselector_src\stdafx.h(21) : fatal error C1083: Cannot open include file: 'ObjModel\addauto.h': No such file or directory Build log was saved at "file://C:\avo\ColorSelector_src\Debug\BuildLog.htm" ColorSelector - 1 error(s), 0 warning(s)

    Reply
  • Crashes VS if no document open.

    Posted by Legacy on 08/28/2003 12:00am

    Originally posted by: Erich W. Einfalt

    If no source code document is open, the toolbar icon still shows to be enabled. If the icon is clicked when no source code document is open, an access violation dialog appears:

    "...instruction at address 0x100041de tried to access memory at 0x00000000. Memory could not be 'read'"

    If no document is open, the toolbar icon should be disabled.

    Reply
  • Woooooooow!! Amazing!!!

    Posted by Legacy on 08/26/2003 12:00am

    Originally posted by: EF

    This the most usfull addin I ever seen!!!

    Goooooooooood Work!!

    Reply
  • Grreat Work

    Posted by Legacy on 08/06/2003 12:00am

    Originally posted by: Nice Life

    Great Idea!!

    Reply
  • Any links to guidelines

    Posted by Legacy on 08/05/2003 12:00am

    Originally posted by: Kiran

    Any links to guidelines to develop an add-in ?

    Thanks,
    Kiran

    Reply
Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • IBM Worklight is a mobile application development platform that lets you extend your business to mobile devices. It is designed to provide an open, comprehensive platform to build, run and manage HTML5, hybrid and native mobile apps.

  • Live Event Date: November 13, 2014 @ 2:00 p.m. ET / 11:00 a.m. PT APIs can be a great source of competitive advantage. The practice of exposing backend services as APIs has become pervasive, however their use varies widely across companies and industries. Some companies leverage APIs to create internal, operational and development efficiencies, while others use them to drive ancillary revenue channels. Many companies successfully support both public and private programs from the same API by varying levels …

Most Popular Programming Stories

More for Developers

Latest Developer Headlines

RSS Feeds