Using Win32 functions in Visual FoxPro Image Gallery
Window
..msdn
CloseWindow
CreateWindow
CreateWindowEx
DestroyWindow
EndTask
FindWindow
FindWindowEx
GetAncestor
GetClientRect
GetDesktopWindow
GetForegroundWindow
GetGUIThreadInfo
GetParent
GetShellWindow
GetWindow
GetWindowInfo
GetWindowPlacement
GetWindowRect
GetWindowText
GetWindowTextLength
GetWindowThreadProcessId
InternalGetWindowText
IsChild
IsIconic
IsWindow
IsWindowVisible
IsZoomed
MoveWindow
RealGetWindowClass
SetForegroundWindow
SetLayeredWindowAttributes
SetParent
SetWindowPos
SetWindowText
ShowWindow
SwitchToThisWindow
Code examples:
An alternative way of setting Form.Closable to False
Comparing dimensions of the VFP main window with _SCREEN properties
Copying picture of the active form to the Clipboard using Enhanced Metafile API functions
GDI+: copying to the Clipboard (a) image of active FoxPro window/form, (b) image file
GDI+: saving image of FoxPro form to graphics file (BMP, GIF, JPG, PNG, TIF)
GDI+: sending image of FoxPro form to printer
GetFocus returns a HWND value
How to copy the image of a form to the Clipboard using Bitmap API functions
How to create transparent areas inside a form -- punching holes in the form
How to make a VFP form fading out when released (GDI version)
How to make a VFP form fading out when released (GDI+ version)
How to print FoxPro form
How to print FoxPro form -- II
Listing child windows for the Windows desktop
Retrieving geometrical parameters of the system desktop window
Retrieving top-child window for the VFP form
Scanning a hierarchy of child windows down from the Windows Desktop
Storing screen shot of a form to bitmap file
Storing screen shot of a form to enhanced metafile (*.emf)
How to create transparent areas inside a form -- punching holes in the form

User rating: 0/10 (0 votes)
Rate this code sample:
  • ~
More code examples    Listed functions    Add comment     W32 Constants      Translate this page Printer friendly version of this code sample
Before you begin:
Holes in a form
A region is a rectangle, polygon, or ellipse or a combination of two or more of these shapes. The SetWindowRgn function sets the window region of a window.

The window region determines the area within the window where the system permits drawing. In other words, parts of the form beyond the region are not visible. Any mouse clicks on invisible parts pass through them to the windows beneath.

See also:
  • How to draw a custom Window Caption on FoxPro form
  • Round FoxPro form
  • An alternative way of setting Form.Closable to False
  • Semi-transparent form
  • Transparent Menu on top-level form (requires VFP9)

  •  
      Members area. Log in to view this example.
     
      User name:
      Password:
     
     
      Forgot your password?
     
      Sign up for
    the Membership
     
     


    User rating: 0/10 (0 votes)
    Rate this code sample:
    • ~
    3402 bytes  
    Created: 2001-08-27 12:00:00  
    Modified: 2011-05-07 15:40:39  
    Visits in 7 days: 139  
    Listed functions:
    CombineRgn
    CreateEllipticRgn
    CreateRectRgn
    DeleteObject
    GetFocus
    GetWindowRect
    SetWindowRgn
    Printer friendly API declarations
    My comment:
    Visual FoxPro 8.0 Samples: Creating Irregularly Shaped Windows Sample.

    The SetLayeredWindowAttributes function can be used for creating transparent areas on forms, and even for making a whole form partially or totally transparent. A layered window is created by specifying WS_EX_LAYERED when creating the window with the CreateWindowEx function or by setting WS_EX_LAYERED via SetWindowLong after the window has been created.

    Only top-level windows (ShowWindow=2) can be made layered windows, whereas through using GDI regions even a child window can be "punched out".

    Read Window Features article on MSDN.
    Word Index links for this example:
    Translate this page:
      Spanish    Portuguese    German    French    Italian  
    FreeTranslation.com offers instant, free translations of text or web pages.
    User Contributed Notes:
    wjarnold@prodigy.net | 2001-10-01 09:33:30
    Basically, the demo brings up a form with a left to right series of "holes" (white, round circles, each an inch or so in diameter) with the circles showing whatever is behind them (that is, through the "holes" they form)

    It gets cooler when you move the demo form around and realize that the holes are showing stuff on your screen that"s behind the form (took a minute to figure that out because I first ran it on an empty screen background <s>).

    One of the more imaginative things I"ve come across in form design in a while.

    Copyright © 2001-2013 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

    Privacy policy
    Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.1.55-log), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
    Last Topics Visited (50.16.132.180)
    2.14 hrs.Example: 'Setting the last-error code for the FoxPro'
     Function: 'CreateSymbolicLink'
    2.24 hrs.Example: 'Creating a console window for Visual FoxPro application'
     Example: 'Converting a hexadecimal string to an integer'
     Example: 'Retrieving graphic capabilities of your display'
    Google
    Advertise here!