Fork me on GitHub

What is mCtrl

mCtrl is open-source C library providing set of additional user interface controls for Windows, intended to be complementary to standard Win32API controls from USER32.DLL and COMCTL32.DLL.

Supported systems

Microsoft Windows 2000, XP, Vista, 7, 8, 8.1, 10 (both 32 bits and 64 bits) are supported.

API

API is based on windows messages, similarly to the API of USER32.DLL and COMCTL32.DLL.

Unicode

Internally all strings are Unicode. The interface mimics the Win32API duality controlled with the preprocessor macro UNICODE.

Consistency

The controls keep consistent look and feel with the system, including support for XP theming aka visual styles.

Button Control

screenshot of the button control screenshot of the button control

Windows XP came with support for visual styles. Unfortunately COMCTL32.DLL did not implement the visual styles for icon buttons (BS_ICON).

It was not until Windows Vista and COMCTL32.DLL 6.0 until the split buttons (BS_SPLITBUTTON, BS_DEFSPLITBUTTON) were supported. Of course a lot of applications implemented them on their own again and again, but that's quite tedious work.

mCtrl button control provides reusable split buttons everywhere where mCtrl is supported (i.e. since Windows 2000) and emulates the styled icon buttons in Windows XP (if the application uses visual styles).

Chart Control

screenshot of the chart control

The name of the chart control says it all. The following chart types are supported with various control styles:

Most of the chart types are available both in a standard as well as in a stacked variant.

Expand Control

screenshot of the expand control

Expand control is a button with a capability to change size of other window (usually the dialog it is located on). It is capable to animate the size transition, and (for well designed dialogs) to magically compute the expanded & collapsed sizes of the dialog form its own position in it.

Grid Control

screenshot of the grid control

Users can easily understand large quantity of data when the data is presented in the right way. In many cases, the grid may be the right way.

HTML Control

screenshot of the HTML control

Embed power of web browser into into your application.

The control is lightweight wrapper of Internet Explorer COM object and allows you to incorporate local or remote HTML content into your programs easily through the SendMessage() as any other control.

Cooperation between the application and HTML may be achieved by getting notifications when user clicks on a link, and by calling JavaScript functions from the application.

Image View Control

screenshot of the image view control

Image view control is similar to standard STATIC control with SS_ICON or SS_BITMAP style, but it is capable to utilize resources of broader image formats (BMP, GIF, JPG, PNG, WMF).

Loading images from files on disk, as well as using resources embedded inside the DLL/EXE.

MDI Tab Control

screenshot of the MDI tab control

Win32API traditionally offers Multiple Document Interface (MDI) for applications with capability to work with multiple documents in a single window. However many uses find MDI unfriendly and surprisingly often they do not understand it.

Modern applications like most web browsers often use tabs for this purpose instead. That's exactly what this control is intended for: It's a tab-like replacement for MDI.

Menubar

screenshot of the menubar control

Instead of standard window menu, many applications use a menubar which can be embedded into REBAR control. This solution allows user to save space on his monitor, by e.g. placing a toolbar and menubar to a single row.

The control also offers a possibility to use the menubar on other places then on top of client area.

Tree-List View Control

screenshot of the tree-list view control

This control combines power of standard tree view and list view (with the LVS_REPORT style).

License

mCtrl is covered by GNU Lesser General Public License version 2.1 (LGPL) or (at your option) newer version of the license.

Few mCtrl source files may be covered by other licenses. In such cases the license terms (or a pointer to them) are mentioned directly in the respective files. We strongly believe that all the used licenses are compatible with the LGPL and allows us to offer and distribute mCtrl as a whole work under the terms of the LGPL.

In brief, this generally means that:

Source code of examples is in public domain, so you may use them, modify them and distribute them as you wish, without any limitation.