The development of components and products
 
 
 



A library for work with irregular window shapes
1992-2003 Studio dmm and MMSW, all rights reserved

Licencing information
This software is a commercial product. If you are a registred user, no royalty-fees are required for distribution
of the software with your applications.
By using the software you're agreeing to the terms and conditions of the Licence Agreement.

Demoversion download
Fully working testing version of the dll (u32) library available, examples in programming languages listed below are enclosed (the demo version is fully working but the library will show a dialogue window).

Authorware 4, 5, 6 demo (130 kB)
Delphi 6 demo (300 kB)
ToolBook 7 demo (110 kB)
VB .NET framework demo (110 kB)

Description
The library allows you to adjust shapes of windows and to work with translucence and transparency of the windows. Most of the functions can be combined with one another so that interesting effects in the windows can appear. 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, 7
Delphi 2, 3, 4, 5, 6, 7
Toolbook 6, 6.5, 7, 7.1, 7.2, 8, 8.5
Visual Basic, language C and others
.NET framework

History
12/03/2003   Version 1.5   The function dmm_AlfaBlendWindow was renamed to
dmm_AlphaBlendWindow
14/12/2002   Version 1.4   The function dmm_FadeFromToWindow was added
The function dmm_MemberRgn was added
17/11/2002   Version 1.3   The function dmm_RectRgn was added
The function dmm_AlfaBlendWindow was added
The function dmm_TransparentColorWindow was added
29/07/2002   Version 1.2   The function dmm_RoundRectRgn was added
10/07/2002   Version 1.1   The function dmm_SetRgnFile was renamed to dmm_BitmapRgn
07/07/2002     Version 1.0     Foundation of the library

List of functions

dmm_RegWindow     Registration of dll (u32)
dmm_BitmapRgn   Adjustment of an irregular window of the application. Shape
of the window is read from an external bmp folder.
dmm_RoundRectRgn   Adjustment of a window with rounded corners
dmm_RectRgn   Adjustment of a rectangle window
dmm_AlphaBlendWindow   Adjustment of window transparency, using alfa channel
(Win NT, 2000, XP)
dmm_TransparentColorWindow   Adjustment of window translucence, using colour
(Win NT, 2000, XP)
dmm_FadeFromToWindow   Time animation of window transparency, using alfa channel
(Win NT, 2000, XP)

Description of functions
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_RegWindow(code:string)
We must call this function before we use the dmm_volume.dll (dmm_volume.u32) library for the first time. If you do not insert the correct registration number a note saying this is a demo version will appear after you start the application.

Parametres
The type of code is string (lpcstr), for the demo version code="demo". For the commercial version the chain is unique.

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 differently irregular. The function reads the mask from an external bmp folder and reduces the window depending on it. What is black is reduced so it is not visible. What is white will stay visible. The window is reduced including all the driving elements. It is necessary to know it.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
The type of file is string and we place here the bmp folder, which the window should be in accordance with (including the path)

Example
dmm_BitmapRgn(handle, "c:\euro.bmp")

Note
It is possible to prepare more than one mask and then to change these masks during the application.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
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 become rounded.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
WidthEllipse is in pixels and it determines a value of camber in horizontal axis. HeightEllipse is also in pixels but it determines a value of camber 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.Extents of the window are defined by the function parametres. This function can cancel the adjustment of dmm_BitmapRgn, dmm_RoundRectRgn, if you place the original window extents.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
Left is in pixels and it determines the x-coordinate of the upper-left window corner. Top is in pixels too and it determines the y-coordinate of the upper-left window corner. Width is size of the window in pixels and so is Height.

Example
dmm_RectRgn(handle,20,25,200,500)
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_AlphaBlendWindow(handle:word, opacity:word)
This function allows you to constitute transparency for alfa windows. It only works in Win NT, 2000, XP.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
The type of opacity is word and the value is from 0 to 100 (it is the value of opacity).
100-opaque window, 0- 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 translucence in the colour system RGB. It only works in Win NT, 2000, XP.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
The type of R, G, B is word and it is adjustment of colour in the RGB system. The parametres can be between 0 and 25.

Example
dmm_TransparentColorWindow(handle,255,0,0) causes that translucent colour will be the red one in the window.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
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 transparency of windows in interval opacity_1 and opacity_2. If the opacity_1 is less than the opacity_2, transparency decreases. In the other case it increases. It only works in Win NT, 2000, XP.

Parametres
The type of handle is word and it is handle of the the window which we want to be changed.
The type of opacity _1 is word and its value ranges from 0 to 100. It shows level of the original transparency.
The type of opacity _2 is word and its value ranges from 0 to 100. It shows level of the final transparency.
100-opaque window, 0- transparent window.
The type of time is word and it adjusts time which the whole animation will take (in milliseconds).
The type of period is word and it is time in which the window will begin to change (time of one section of the animation). The period can range from 5ms to 5000ms.
If you choose, for instance, time=5000ms and period=20ms, then the window will be repainted 50 times during the whole animation. We must realise that during the animation processor must recount the whole application window and it means it is extremely busy. That is why we must choose the period intelligently. With some computers it is possible that the animation will take longer than we have adjusted. It is because the processor is busy.

Example
dmm_FadeFromToWindow(handle,100,25,1000,25);
dmm_FadeFromToWindow(handle,25,100,2000,50);
This will make the window disappear fluently and display again.
-----------------------------------------------------------------------------------------------------------------------------------------------------------

Important
Most of the functions can be combined with one another so that you can reach very interesting shapes and effects of the windows.

 


© Studio dmm 1992-2005, all rights reserved, other information regarding our components: software@dmm.cz