archive-com.com » COM » E » EFG2.COM

Total: 878

Choose link from "Titles, links and description words view":

Or switch to "Titles and links view".

  • begin FormDC GetWindowDC Form Handle CyCaption GetSystemMetrics SM CYCAPTION Height of Title bar CxSize GetSystemMetrics SM CXSIZE Width of button in title bar CxDlgFrame GetSystemMetrics SM CXDLGFRAME Thickness of frame CyDlgFrame GetSystemMetrics SM CYDLGFRAME Thickness of frame CxEdge GetSystemMetrics SM CXEDGE 3D border thickness CyEdge GetSystemMetrics SM CYEDGE 3D border thickness SxIcon GetSystemMetrics SM CXSMICON Recommended icon x size SyIcon GetSystemMetrics SM CYSMICON Recommended icon y size FormStyle GetWindowLong Form Handle GWL STYLE FormIcons Form BorderIcons Make sure there s a title bar to draw in if FormStyle and WS CAPTION WS CAPTION then begin Check what title bar buttons are shown BorderIconCount 1 if biMinimize in FormIcons then inc BorderIconCount if biMaximize in FormIcons then inc BorderIconCount if biSystemMenu in FormIcons then inc BorderIconCount Resize Bitmap to recommended title bar icon sizes ARect Rect 0 0 SxIcon SyIcon Bitmap Canvas StretchDraw ARect Bitmap Calculate left and top starting point of image ImgLeft Form Width BorderIconCount CxSize CxDlgFrame CxEdge ImgTop CyCaption CyDlgFrame CyEdge Bitmap Height div 2 Mask TBitmap Create Mask Assign Bitmap Mask Mask Bitmap TransparentColor try TransparentStretchBlt FormDC ImgLeft ImgTop Bitmap Width Bitmap Height Bitmap Canvas Handle 0 0 Bitmap Width Bitmap Height Mask Canvas Handle 0 0

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/2001/0405d.txt (2016-02-14)
    Open archived version from archive



  • undoes the transparency mask A second method which I use has been coined as the black source method It eliminates one of the BitBlt calls in the traditional method It requires a monochrome mask a transparency mask has colour information and a monochrome mask does not It also requires some modification of the source image Basically you replace your transparency colour with black hence black source What this means is that one way or another you are going to require a mask which can be applied before you blit your real image I highly recommend that you look through all of the following Microsoft knowledge base articles about transparency the second article applies to an API behaviour issue Windows 95 and NT 3 51 client machines SAMPLE TRANSBLT Demonstrates Bitmaps with Transparency http support microsoft com support kb articles q97 3 65 asp PRB Trouble Using DIBSection as a Monochrome Mask http support microsoft com support kb articles q149 5 85 asp HOWTO Drawing Transparent Bitmaps http support microsoft com support kb articles q79 2 12 asp Here s my recommendations 1 Use the black source method if you can It is easier and faster 2 Generate your monochrome mask

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/1999/0518.txt (2016-02-14)
    Open archived version from archive


  • my component but instead of copying the form I get the background of my desktop I guess that somehow the BitBlt is done before the form is created If I understand your question correctly you want to copy the area behind your component Here is a function that I use in some transparent components I have written procedure DrawParentImage Control TControl Dest TCanvas var SaveIndex Integer DC HDC Point TPoint

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/1999/0703b.txt (2016-02-14)
    Open archived version from archive


  • TComponent override end procedure Register implementation uses Windows TTransparentMemo procedure TTransparentMemo WMHScroll var Message TWMHScroll begin inherited PostMessage Handle TMWM SpecialInvalidate 0 0 end procedure TTransparentMemo WMVScroll var Message TWMVScroll begin SendMessage Handle TMWM SpecialInvalidate 0 0 inherited PostMessage Handle TMWM SpecialInvalidate 0 0 end procedure TTransparentMemo CNCTLCOLOREDIT var Message TWMCTLCOLOREDIT begin with Message do begin SetBkMode ChildDC TRANSPARENT Result GetStockObject HOLLOW BRUSH end end procedure TTransparentMemo WMSetText var Message

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/2000/1129a.txt (2016-02-14)
    Open archived version from archive


  • all the icons That s why writing onto this DC will overwrite all windows at this position Try this routine it works great for me And don t forget to invalidate the area you painted on without erasing the background so that the icons are redrawn procedure TForm1 Button1Click Sender TObject function GetDesktopListViewHandle THandle var S String begin Result FindWindow ProgMan nil Result GetWindow Result GW CHILD Result GetWindow Result

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/2002/0902.txt (2016-02-14)
    Open archived version from archive


  • 0 Newsgroups borland public delphi winapi I have a program that changes the wallpaper automatically and I use the following code to do it SystemParametersInfo SPI SETDESKWALLPAPER 0 PChar BmpName SPIF UPDATEINIFILE Essentially the same as your code but using the SPIF UPDATEINIFILE flag I found out that if I didn t use that flag the Wallpaper change sometimes wouldn t stick SeAn wrote Hi I m really confused with

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/1999/0425b.txt (2016-02-14)
    Open archived version from archive


  • file name so it doesn t fill up my hard drive eg Wallpaper bmp It s a trivial task to copy a jpg to a bitmap and save the bitmap I also use a TImage because it will handle all the registered file formats Image1 Picture LoadFromFile fnm can be a bmp jpg or wmf i don t do icons they make bad wallpaper bm Width Image1 Width an internal tbitmap bm Height Image1 Height If wmf erase background first because of transparency if Image1 Picture Graphic is TMetaFile then bm Canvas FillRect RECT 0 0 bm Width bm Height fill background with whatever the bm brush color is bm Canvas Draw 0 0 Image1 Picture Graphic Image1 can be Visible false if you don t require a preview mechanism Then set the bm as wallpaper var wd array 0 63 of Char Windows Directory GetWindowsDirectory wd 63 s wd Wallpapr bmp s is a string variable wd is the Windows directory bm SaveToFile s SystemParametersInfo SPI SETDESKWALLPAPER 0 PChar s 0 R TRegistry Create R OpenKey Control Panel desktop FALSE R WriteString Wallpaper s R Free Patrick Dugan wrote I can load a BMP as wallpaper by using the

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/1999/0629a.txt (2016-02-14)
    Open archived version from archive


  • in SystemParametersInfo are the key procedure ChangeIt var Reg TRegIniFile begin Reg TRegIniFile Create Control Panel Reg WriteString desktop Wallpaper c windows forest bmp Reg WriteString desktop TileWallpaper 1 Reg Free SystemParametersInfo SPI SETDESKWALLPAPER 0 nil SPIF SENDWININICHANGE end Regards David BOCOsoft wrote in message news 7l9qb8 o4t7 forums borland com I am working on a program that changes wallpaper everytime it is run When I run it from Delphi

    Original URL path: http://www.efg2.com/Lab/Library/UseNet/1999/0629b.txt (2016-02-14)
    Open archived version from archive



  •