Library for Work with Irregular Window Shapes
© 1992-2005 Studio DMM and MultiMedia SoftWare, all rights reserved
Description
This library allows you to adjust the shapes and transparency of the windows.
Some of the functions can be combined to get interesting effects. The library
works in Windows. Some functions only work in Windows 2000 and XP.
Library is compatible with
Authorware 3, 3.5, 4, 5, 6, 6.5
Delphi 2, 3, 4, 5, 6, 7
Toolbook 6, 6.5, 7, 7.1, 7.2, 8, 8.5
Visual Basic, C Language and others
.NET Framework
List of functions
| dmm_RegWindow |
Registration of DLL (U32) |
| dmm_BitmapRgn |
Adjustment of the irregularity of a window
Shape of the window is read from an external b/w BMP file |
| dmm_RoundRectRgn |
Adjustment of corners rounding of a window |
| dmm_RectRgn |
Adjustment of a rectangle window |
| dmm_AlphaBlendWindow |
Adjustment of window transparency, using alpha channel
(Win NT, 2000, XP) |
| dmm_TransparentColorWindow |
Adjustment of selected color transparency of a window
(Win NT, 2000, XP) |
| dmm_FadeFromToWindow |
Time animation of window transparency, using alpha channel
(Win NT, 2000, XP) |
Descriptions of functions
void = dmm_RegWindow(code:string)
You must call this function before you use the dmm_window.dll
(dmm_window.u32) for the first time. If you do not insert the correct
registration Code, a dialog saying "this is a demo version ... " will appear.
Parametres
The type of
code is STRING (LPCSTR), for the demo version
code="demo". For the commercial version the code is unique for each
license.
Example
dmm_RegWindow("demo")
void = dmm_BitmapRgn(handle:word, file:string)
This function allows you to create applications whose window is not rectangular
but rounded or irregular in some other way. The function reads the mask from an
external b/w BMP file and, accordingly, cuts the shape of the window.
Black is transformed to fully transparent parts of the window. White is
transformed to the visible parts of the window. We would like to point out that
the window is reduced including all the control elements.
Parametres
The type of
handle is WORD and we fill in the name (incl. the path
if necessary) of the BMP file here.
Example
dmm_BitmapRgn(handle, "c:\euro.bmp")
Note
You can prepare more than one mask and then change these masks on the fly.
void = dmm_RoundRectRgn(handle:word, widthEllipse:word, heightEllipse:word)
This function allows you to create applications whose windows are rounded.
The window size will not change; only the corners will be rounded.
Parametres
The type of
handle is WORD and it is the handle of the window you
want to change.
WidthEllipse is the camber size in pixels in horizontal axis.
HeightEllipse is the camber size in pixels in vertical axis.
Example
dmm_RoundRectRgn(handle,20,25)
void = dmm_RectRgn(handle:word, left:word, top:word, width:word, height:word)
This function allows you to create applications whose windows are
rectangular. The window size is defined by the function parameters. This
function can cancel the usage of functions dmm_BitmapRgn, dmm_RoundRectRgn if
you use the original window size.
Parametres
The type of
handle is WORD and it is the handle of the window you
want to change.
X is expressed in pixels and the value determines the x-coordinate of
the upper-left window corner.
Y is also expressed in pixels and the value determines the y-coordinate
of the upper-left window corner from the top of the screen.
The
width and the
height of the window are expressed in pixels.
Example
dmm_RectRgn(handle,20,25,200,500)
void = dmm_AlphaBlendWindow(handle:word, opacity:word)
This function allows you to determine the transparency for alpha windows.
It works in Win NT, 2000, XP only.
Parametres
The type of
handle is WORD and it is the handle of the window you want
to change.
The type of
opacity is a WORD and the value must range from 0
to 100 (100-opaque window, 0- fully transparent window).
Example
dmm_AlphaBlendWindow(handle,25)
void = dmm_TransparentColorWindow(handle:word, r:word, g:word, b:word)
This function allows you to create translucent windows. You adjust the
translucence in the RGB color system. It works in Win NT, 2000, XP only.
Parametres
The type of
handle is WORD and it is the handle of the window which
we want to change.
The types of R, G, B are WORD and represent the adjustment of color in the
RGB system. The parameters must range from 0 to 255.
Example
dmm_TransparentColorWindow(handle,255,0,0) makes translucent color red.
void = dmm_FadeFromToWindow(handle:word, opacity_1:word, opacity_2: word,
time:word, period :word)
This function allows you to animate transparency of windows. The
dmm_FadeFromToWindow function animates opacity of a window from opacity_1
to opacity_2. It works in Win NT, 2000, XP only.
Parametres
The type of
handle is WORD and it is the handle of the window which
we want to change.
The type of
opacity_1 is WORD and its value ranges from 0 to
100. It determines the initial opacity.
The type of
opacity_2 is WORD and its value ranges from 0 to
100. It determines the final opacity.
(100-opaque window, 0- fully transparent window)
The type of
time is WORD and it adjusts the animation transition
period in milliseconds.
The type of
period is WORD and it represents the period in which
the window is repainted (time of one section of the animation). The period can
range from 5 ms to 5000 ms. For example, if you choose time=5000 ms and
period=20 ms, the window will be repainted 250 times during the whole
animation. We should realize that the processor must recount the whole
application window during the animation and this takes the CPU time. Thus, we
should choose the animation time and period carefully in regards to the target
PCs. Slower computers may take longer to show the animation than we have set it
for.
Example
dmm_FadeFromToWindow(handle,100,25,1000,25);
dmm_FadeFromToWindow(handle,25,100,2000,50);
This will make the window disappear and then reappear fluently.
Important
Some of the functions can be combined and this fact enables you to obtain very
interesting shapes and effects of the windows.
Demoversions to download
Fully-functional testing versions of the DLL (U32), that can be used in most of
programming languages, are available for download (these demoversions are fully
functional, but the library will show a dialog window).
Licensing
-
Developer license
This license authorizes the developer to use the component while creating his
own applications and add the component free of charge to the applications he
has created. Under no circumstances is the developer permitted to distribute
the component independently, include it in applications created by a third
party, and disclose the Code to a third party.
Price of Developer License is 50,- € (EUR).
-
Company license
This license authorizes all company developers to use the component while
creating their own applications and the company is permitted to add the
component free of charge to the applications they have produced. Under no
circumstances is the company permitted to distribute the component
independently, include it in applications created by a third party, and
disclose the Code to a third party.
Price of Company Licence is 100,- € (EUR).
Window-shaping and Color-changing Component can be bought in our
SHOP.