Using Win32 functions in Visual FoxPro Image Gallery
Code examples:
How to change display settings: screen resolution, screen refresh rate
Adding and deleting Scheduled Tasks using NetScheduleJob API functions
Custom GDI+ class
Capturing keyboard activity of another application with the Raw Input API (VFP9)
Converting Unicode data from the Clipboard to a character string using a given code page
Winsock: sending email messages (SMTP, port 25)
Enumerating data formats currently available on the clipboard
Custom FTP Class for Visual FoxPro application
Splash Screen for the VFP application
Detecting changes in connections to removable drives (VFP9)
How to download a file from the FTP server using FtpGetFile
How to activate Windows Calculator
Custom HttpRequest class (WinHTTP)
Establishing connection using the SQLDriverConnect
How to convert a bitmap file to monochrome format (1 bpp)
How to put a vertical text scrolling on the form (a movie cast)
Displaying bitmap using the AlphaBlend function
Mapping and disconnecting network drives
Using Font and Text functions
Using WM_COPYDATA for interprocess communication (VFP9)
GDI+: copying to the Clipboard (a) image of active FoxPro window/form, (b) image file
Enumerating raw input devices attached to the system (keyboard, mouse, human interface device)
Displaying animated images on FoxPro form with BitBlt and StretchBlt functions
How to play AVI file on the _screen
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: 105  
    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 (54.234.42.16)
    2.53 hrs.Example: 'Winsock: connecting to a news server (NNTP, port 119)'
     Example: 'GetFileOwner - Get the owner of an NTFS file'
    11.62 hrs.Example: 'How to remove a directory that is not empty'
     Example: 'Setting the date and time that a file was created'
    15.13 hrs.Example: 'Winsock: retrieving information from a host database for a given host name'
     Function: 'GdipScaleMatrix'
    Function group: 'GDI+ Matrix'
    15.25 hrs.Example: 'How to disable the Windows Clipboard (VFP9)'
    Language: 'C#'
     Example: 'Windows Shell Icons displayed and exported to ICO files (Vista)'
    17.83 hrs.Example: 'Displaying the drive type value'
     Function: 'ControlService'
    Google
    Advertise here!