2025-11-27 16:46:48 +09:00

17 lines
2.4 KiB
Plaintext
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{\rtf1\ansi\deff0\deftab720{\fonttbl{\f0\fswiss MS Sans Serif;}{\f1\froman\fcharset2 Symbol;}{\f2\froman Times New Roman;}{\f3\froman Times New Roman;}}
{\colortbl\red0\green0\blue0;\red0\green0\blue128;\red128\green0\blue0;}
\deflang1033\pard\plain\f3\fs36\cf1\b Extended Spincontrol class\plain\f3\fs36\b
\par \plain\f3\fs24\cf2\b Ultimate ToolBox COXSpinCtrl class\plain\f3\fs28\b
\par
\par \plain\f3\fs20 The class COXSpinCtrl is a class that extends the MFC class CSpinButtonCtrl. So in fact it extends the functionality of the common control that is being wrapped by MFC.
\par
\par Apart from the two buttons (up and down) it shows a small rectangle (called "the spin thumb") in between these two buttons. When the user clicks and holds this rectangle, the mouse cursor will change shape, and user can drag the mouse to increase or decrease the value.
\par
\par Up and down buttons have the same effect as these buttons on the standard spin control. Extended functionality of the thumb can be switched off (even during run-time). So if it's necessary, COXSpinCtrl can be used exactly as the standard spin, because functionality of MFC's CSpinButtonCtrl is completely supported (inherited) by COXSpinCtrl.\plain\f3\fs24
\par \plain\f3\fs28\b Features:
\par \pard\li720\fi-360{\*\pn\pnlvlblt\pnf1\pnindent360{\pntxtb\'b7}}\plain\f3\fs20 {\pntext\f1\'b7\tab}The thumb enabling or disabling is set during COXSpinCtrl object construction, but you can swap its enabling/disabling at the any moment later.\plain\f3\fs24
\par \plain\f3\fs20 {\pntext\f1\'b7\tab}Mouse double click on the thumb swaps the spin value between the outer limits. If the spin value doesn't equal any of outer limits, double click set it to the nearest limit.\plain\f3\fs24
\par \plain\f3\fs20 {\pntext\f1\'b7\tab}When user clicks the thumb and drags the mouse, change of mouse coordinates is translated to spin value change. COXSpinCtrl supports two methods of such translation: a) one screen pixel corresponds to one spin unit; and b) screen borders are considered as spin value limits, so one spin unit can be correlated with various number of pixels. These methods are represented by its constants and carried out by virtual function ComputeValueFromDeltaPixel(). So user can define his/her own constants and override this function to realize own translation methods.\plain\f3\fs24
\par \pard\plain\f2\fs20
\par }