HDTenEightyP/NetNews huggingface dataset:
From: ftsai@bronze.ucs.indiana.edu (fu-hwai tsai)
Subject: How to change wallpaper? (Sample code appreciated.)
Organization: Indiana University
Date: Fri, 14 Aug 1992 03:01:36 GMT

Dear  readers:

I'll appreciate if there is anyone who can tell me where to get sample
codes to change the window wallpaper.  I've check the SDK reference
manuals and several window programming books and couldn't find any
help from them.  Basicly, I need the program code which can remove the
current wallpaper from windows and then put the new wallpaper BMP
file.  Any information will be highly appreciately.

Thanks in advance,
Claire
ftsai@bronze.ucs.indiana.edu
School of Library & Information Science
Indiana University, Bloomington

Newsgroups: comp.windows.ms.programmer,comp.os.ms-windows.programmer.misc
From: jeroenp@rulfc1.LeidenUniv.nl (Jeroen W. Pluimers)
Subject: Re: Removing & UnRemoving SysMenu, TitleBar, MinMax buttons
Organization: Dept. FMC, Gorlaeus Labs, Leiden University, The Netherlands
Date: Wed, 12 Aug 92 18:39:57 GMT

In article <1992Aug11.220535.14031@u.washington.edu> goble@hardy.u.washington.edu (Brian Goble) writes:
>I am trying to make my Windows app capable of dynamically changing 
>I am writing a program that sometimes will be on display and I don't
>want the users to be able to resize the window, minimize it, close it, etc.
>(although I'll implement a "secret" method to regain control :)
>
>Rather than just trapping the above messages, I'd rather "remove" (or hide)
To get rid of the buttons, create your window without the ws_MinimizeBox
and ws_MaximizeBox.

Tchange the system menu, get a menu handle as follows:
  
  hMenu := GetSystemMenu(hWindow, False);

Then you can modify the menu as follows (for instance to remove the Close
option):

  ModifyMenu (hMenu, sc_Close, mf_ByCommand + mf_Grayed);

This will gray the Close option.


--
    o _   _  _   _   _             voice: +31-2522-20908 (19:00-24:00 UTC)
   / (_' |  (_) (_' | |            snail: P.S.O.
__/                                       attn. Jeroen W. Pluimers
                                          P.O. Box 266
jeroenp@rulfc1.LeidenUniv.nl              2170 AG Sassenheim
jeroen_pluimers@f521.n281.z2.fidonet.org  The Netherlands
From: gxlr07@udcf.glasgow.ac.uk (Brian Syme)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Need a Mac CloseView style driver - DDK?
Date: 17 Aug 92 13:57:03 GMT
Organization: Glasgow University Computing Service


I need an equivalent of the Mac's CloseView screen magnifier for windows. I
don't know of any such thing for windows, either PD or commercial at the
moment, so I'm considering rolling my own. Could someone in the know give me
an idea of how difficult this is (I assume the DDK comes with sample drivers
that could be modified...) and how much the DDK/docs cost?..

----------------------------------------------------------------------
Brian Syme, Glasgow University Library. | gxlr07@udcf.gla.ac.uk
----------------------------------------- Phone: UK 041-339-8855 x6734
From: mg@spox.spectron (Mark Grosen)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: Problem with dialog as main window
Keywords: windows,dialog,petzold
Date: 20 Aug 92 03:05:12 GMT
Distribution: na
Organization: Spectron MicroSystems, Inc., Santa Barbara,  CA

mg@spox.spectron (Mark Grosen) writes:


>Sorry for a repeat question, but I did not see a reply to an earlier posting
>about this problem.  I, too, am trying out the "hexcalc" program from the
>original Petzold book.  This app just does a CreateDialog() to make its main
>window.  Well, the code no longer seems to work under 3.1.  I can't find a

I will answer my own question and for those of you wondering too.
The problem with hexcalc in the original Programming Windows (Ed. 1) was
that the window class for the dialog did not include the extra bytes
needed for dialog boxes (cbWndExtra = DLGWINDOWEXTRA).  After this simple
change, all is fine.  I found the answer from the verstamp example in
the SDK, which uses the same technique.

Mark


-- 
Mark D. Grosen			
Spectron MicroSystems		Internet:  mg%spox@hub.ucsb.edu
5266 Hollister Avenue		(805) 967-0503 (Voice)
Santa Barbara, CA  93111	(805) 683-4995 (FAX)
Newsgroups: comp.os.ms-windows.programmer.misc
From: mats@infolog.se (Mats Lordin)
Subject: ToolBar feature
Organization: Infologics AB
Date: Mon, 17 Aug 1992 15:33:14 GMT

I want to include a ToolBar in my application. I have received example
source code from Microsoft on how to do this. The problem is that I don't
understand how the ToolBar, which is an child window, excludes the 
possibility of moveing other childwindows completely under the window. I.e
the same way you are unable of completely hiding any childwindow under the
apps menu bar. Could anyone tell me how the client area of the main window
is reduced in size or however it's done so that you can't hide other
childwindows under my own ToolBar.

Thanks

Mats Lordin
Infologics AB
Sollentuna Sweden

E-Mail: mats@infolog.se
From: sloof@cs.vu.nl (Mark Sloof)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: detecting end of task
Date: 13 Aug 92 08:04:02 GMT

I am developing an application to build, generation and run simulations. 
To compile a simulation program, I use WinExec() to start a MAKE utility.

Now I want to detect when MAKE has ended. Is there any possibility to do
this (a function like EndTask) ?

I am using BC++ 3.0 with OWL and Windows 3.0

Please send any suggestions to sloof@ato.agro.nl

---------------------------------------------------------------------------
Mark Sloof            | tel:    +31.8370.75076       | For every problem
ATO-DLO               | fax:    +31.8370.12260       | there is a solution
Postbus 17,           |                              | that is neat, simple
6700 AA Wageningen    |                              | and wrong
the Netherlands       | e-mail: sloof@ato.agro.nl    |
---------------------------------------------------------------------------

Newsgroups: comp.os.ms-windows.programmer.misc
From: hihunn@vex.ugcs.caltech.edu (Heath I Hunnicutt)
Subject: How to make a graphical startup window.
Organization: California Institute of Technology, Pasadena
Date: Thu, 20 Aug 1992 04:19:25 GMT

Hello,	
	Lots of apps these days display a graphical logo/copyright
message, etc., window when they start up.  Usually, the window is
frameless, and appears centered over the forming app window.  My
question is, what methods are there for creating such windows?
How are they filled with wall-to-wall bitmap?  

Curious,
Heath
From: wew@naucse.cse.nau.edu (Bill Wilson)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: pif file layout
Keywords: windows
Date: 19 Aug 92 15:42:26 GMT
Organization: Northern Arizona University, Flagstaff AZ

Does anyone have the layout of pif files.  We would like to
put together a utility that will print out the pif settings
for Windows 3.0 and 3.1.  Screen captures of them take a lot
of time...

-- 
Let sleeping dragons lie........                    | The RoleMancer 
--------------------------------------------------------------------
William Wilson (wew@naucse.cse.nau.edu | wilson@nauvax)
Northern AZ Univ  Flagstaff, AZ 86011
Newsgroups: comp.os.ms-windows.programmer.misc
From: cnolan@vax1.tcd.ie
Subject: How to test for menu bar double up when resizing window?
Organization: Trinity College Dublin
Date: Sat, 15 Aug 1992 18:53:59 GMT

I use the following code to resize a window to that of a bitmap I'm 
displaying.  This assumes that the menu bar is not doubled up which it will 
be for small images.  I have tried various methods to test if the bar is 
going to be doubled, some don't work, others are just tacky; images 
flashing for a while.  
What is the best/proper way to check if the menu bar is going to be 
doubled?  When is the window actually resized?  At the next paint or 
immediately after the SetWindowPos command?


BTW I'm doing this from home and don't have the SDK sample code to peruse.

Conor Nolan

#############################################################################

Code fragment ...

&     w.x=(int)dwImageWidth+ (GetSystemMetrics(SM_CXFRAME)*2);
&
&     // Set the width and see if the client rect is correct.
&     // If not it's because (I hope) the menu bar is doubled
&     w.y=(int)dwImageHeight+(GetSystemMetrics(SM_CYFRAME)*2)+
&                                             GetSystemMetrics(SM_CYCAPTION)
&                                             GetSystemMetrics(SM_CYMENU);
&
&
&     SetWindowPos(hWnd, NULL,0,0,w.x, w.y, SWP_NOMOVE);
&

#############################################################################


-- 
===============================================================================

             
       	 	Conor Nolan			Phone:	772941 (X1741)
           	Microelectronics Dept.		Fax:	772442
            	Trinity College			
	      	Dublin 2			cnolan@mee.tcd.ie
  	     	IRELAND
            

===============================================================================
From: n8642323@henson.cc.wwu.edu (Baine Werny)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: VB: Example functions?
Date: 14 Aug 92 00:47:30 GMT
Article-I.D.: henson.1992Aug14.004730.3978
Organization: Western Washington University

Does anyone know how to do a file copy in VB and keep the files date? There
is a sample procedure in the docs which will copy a file but it changes the
date of the new file to the current system date.

Are there any FTP sites that might have the VBX's I need.

BTW: does anyone know of a FTP site that has any VBX files or public domain
VB controls?

-- 
Baine Werny, n8642323@henson.cc.wwu.edu or BAINEW@nessie.cc.wwu.edu
"This is my stupid quote." -BW
From: geiser@pictel.com (Wayne Geiser)
Newsgroups: comp.windows.ms.programmer,comp.os.ms-windows.programmer.misc
Subject: Re: Setting Client Area to entire screen
Date: 14 Aug 92 16:38:06 GMT
Organization: PictureTel Corporation

In article <1992Aug11.233710.18600@u.washington.edu> goble@hardy.u.washington.edu (Brian Goble) writes:
>How do Win apps such a WinGif (and many other graphics/paint programs)
>implement their "Full Screen" option?  That is, what are they doing to
>make their Client Area the entire screen (no windows stuff at all--it's
>all client area).
>
>Thanx for any info!
>
>-Brian
>
>
>-- 
> ==)------------
>               Brian Goble    |    goble@hardy.u.washington.edu
>               "Finishing a close second means you didn't win."
>                                                              ------------(==

Try:

        hwnd = CreateWindow(YourWindowClassHere, WS_POPUP, 0, 0, 0, 0,
                            NULL, NULL, hInstance, NULL);
        ShowWindow(hwnd, SW_SHOWMAXIMIZED);


**********************************************************************
* Wayne Geiser ("Drivel King")           Voice:    (508) 977-8253    *
* PictureTel Corporation                 FAX:      (508) 532-6893    *
* One Corporation Way                    Internet: geiser@pictel.com *
* Peabody, MA      01960                 CIS:      70313,3615        *
**********************************************************************
"The pope!  How many divisions has he got?"

        - Josef Stalin (in 1935).
Newsgroups: comp.os.ms-windows.programmer.misc
From: mmccarri@physics.ucla.edu (Mike McCarrick)
Subject: How can I get more memory in an edit control?
Organization: UCLA Department of Physics
Date: Thu, 13 Aug 92 08:18:26 GMT

I think I've seen this before, but I can't find the answer.
The edit control that I create in my program runs out of
memory after a few hundred characters are typed.  How do
I get even close to a full 64K of memory for my edit box?
I remember something about giving the CreateWindow call
a global memory handle instead of my own hInstance handle,
but I can't get it to work without more specific instructions.
Does anyone have this information handy?

Thanks in advance.
-- 
Dr. Michael McCarrick                   UCLA Department of Physics
Plasma Physics Lab                              405 Hilgard Avenue
mmccarri@physics.ucla.edu                    Los Angeles, CA 90024
From: nsilva@pdaxs.techbook.com (nsilva)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Linking OWL as a DLL?
Date: 17 Aug 92 07:30:23 GMT
Article-I.D.: pdaxs.c24mPB1w165w
Organization: Portland Public Access sponsored by TECHbooks Bookstore


What is the proper way to link my TCW application with OWL.DLL?

I've followed the directions in the Fine Manual: (a) define _CLASSDLL,
(b) link in the large memory model, (c) use smart callbacks, and
(d) add OWL.LIB, TCLASSDLL.LIB, and CRTLDLL.LIB to the project file.
But I end up with dozens of undefined symbols, such as:

Linker Error: Undefined symbol TWindow::TWindow(TWindowsObject...
Linker Error: Undefined symbol Object::operator new(unsigned i...
Linker Error: Undefined symbol TWindow::GetWindowClass(tagWNDC...
Linker Error: Undefined symbol TApplication::~TApplication() i...
etc.
etc.
etc.


BTW, I'm using TCW 3.0, and Windows 3.1 (yes, I'm going to upgrade
soon).

Nate
nsilva@pdaxs.techbook.com

---
nsilva@pdaxs.techbook.com (nsilva) (Public Access User)
pdaxs gives free access to news & mail. (503) 644-8135 - 1200/2400, N81  
Send to info@techbook.com for more information.
Public access users are <NOT> affiliated with TECHbooks.  
Newsgroups: comp.os.ms-windows.programmer.misc,comp.windows.ms.programmer
From: grussell@hemel.bull.co.uk (Graham Russell)
Subject: Detecting right mouse clicks on desktop - How?
Summary: Detecting right mouse clicks on desktop - How?
Keywords: right desktop
Organization: Bull HN UK
Date: Tue, 18 Aug 92 10:52:34 GMT

How can a program detect either single or double right mouse clicks
on the main Windows desktop?
Newsgroups: comp.os.ms-windows.programmer.misc
From: whedon@netcom.com (Bill Whedon)
Subject: Re: What is the windows call to find the video mode?
Date: Wed, 12 Aug 92 20:30:21 GMT
Organization: Netcom - Online Communication Services  (408 241-9760 guest) 

In article <l8ijr3INN8qr@predator.cs.utexas.edu> marty@cs.utexas.edu (Marty J. Sirkin) writes:
>I have a very simple question (the answer to which I have been
>unable to find in my very badly organized manuals).
>
>I want, at the start of an app, to be able to determine the
>video mode in which windows is running.  Specifically I 
>want to know if it is a 16 or 256 (or 32K) color mode so
>that I can use one of several bitmaps for the intro screen.
>
>I have been unable to find the proper call, and I'm sure someone
>out there can answer this very simply.
>
>Thanks!
>Marty Sirkin
There is no single call which will return all the information you want
at once.  I believe you need to call GetDeviceCaps with the nIndex
parameter set once for each item of information you need.  Information
like this is in "Programming Windows", by Charles Petzold, published
by Microsoft Press, ISBN 1-55615-264-7.  If you don't have it, you need
to quit programming Windows until you get it.

You can also see the SDK Reference for the specific index parameter
values for each tidbit of data you wish to request.  I don't recommend
using the SDK docs as a textbook, but a quick glance through them on
occasion sure wouldn't hurt.  Take 'em to the head with you, or to the
opera when your wife/husband/friend drags you along.

Now.  I've not only bitched at you to  RTFM, but also provided an
answer for your question.  I hope you appreciate the fact that many of
our colleagues would only have done the former.  RTFM, dude.
Peace,
Bill Whedon 

Newsgroups: comp.windows.ms.programmer,comp.os.ms-windows.programmer.misc
From: jeroenp@rulfc1.LeidenUniv.nl (Jeroen W. Pluimers)
Subject: ToolBox with buttons in MDI environment
Organization: Dept. FMC, Gorlaeus Labs, Leiden University, The Netherlands
Date: Sat, 15 Aug 92 08:39:24 GMT


Hi All,


I want to make my own ToolBox like BC++ has in an MDI environment.
The code has to work in TPW, but examples in C are welcome too.

I tried the followind:

constructor TButtonsDialogWindow.init;
begin
  TJanusDialogWindow.Init(aParent, aName, BorStyle);
  SetFlags(wb_MDIChild, False);
end;

procedure TButtonsDialogWindow.GetWindowClass(var AWndClass: TWndClass);
begin
  TJanusDialogWindow.GetWindowClass(AWndClass);
  AWndClass.hIcon := LoadIcon(HInstance, MakeIntResource(icButtons));
  { Attr.Style := Attr.Style or ws_Group or ws_TabStop or
                  ws_Child or ws_OverlappedWindow or ws_Visible; }
end;

The style is as follows:

STYLE WS_CHILD | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX


And it is used in the main program like this:

constructor TMDIdBaseWindow.Init;
begin
   TMDIWindow.Init(ATitle, AMenu);
   Attr.Style := Attr.Style or ws_ClipChildren;
   { ChildMenuPos := 3; }
end;

procedure TMDIdBaseWindow.SetupWindow;
begin
  TMDIWindow.SetupWindow;
  { MenuItems(Disable); }
  Application^.MakeWindow(
end;


The problem is that the ToolBox doesn't get the focused caption (I can press
buttons and move the window), and when the MDI frame is restored from a 
minimized state, the ToolBox sometimes draws partly over the active MDI child.

--
    o _   _  _   _   _             voice: +31-2522-20908 (19:00-24:00 UTC)
   / (_' |  (_) (_' | |            snail: P.S.O.
__/                                       attn. Jeroen W. Pluimers
                                          P.O. Box 266
jeroenp@rulfc1.LeidenUniv.nl              2170 AG Sassenheim
jeroen_pluimers@f521.n281.z2.fidonet.org  The Netherlands
From: azarian@hpcc01.corp.hp.com (Randy Azarian)
Date: Fri, 21 Aug 1992 01:31:11 GMT
Subject: GDI: Drawing a dotted line
Organization: the HP Corporate notes server
Newsgroups: comp.os.ms-windows.programmer.misc

I want to draw a line with alternating pixels; in other words, a dotted line.
CreatePen provides a number of patterns that I am able to use, however what
they call PS_DOT alternates about every two or three pixels, but not what I
want, which is to alternate *every* pixel.

Realizing that CreatePen probably won't work for me, I created a bitmap 
with alternating pixels (8x8) and used PatBlt to copy the bitmap (in a 
single-line width) to the device.  This works, but it is way too slow.

I even tried using my own line-drawing algorthm and using SetPixel and
alternating pixels.  This is even slower.

When I use LineTo with CreatePen, the results are almost instantaneous.
With the other two methods I described, there is a *noticable* line trace.

Can anyone help me to find a way to draw a *true* dotted line ... fast and easy
(well, easy is not so important, but fast is).  Possibly there is some way
to modify an HPEN after I generated it using CreatePen.

I would think that this would be a common item to use.  


Thanks for any help.

-------
Randy Azarian
HP PAITC
From: bytor@milton.u.washington.edu (Jill Patterson)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: BC++ OWL TEdit Questions
Date: 21 Aug 92 17:26:02 GMT
Article-I.D.: milton.bytor.714417962
Organization: University of Washington

bytor@milton.u.washington.edu (Jill Patterson) writes:

>  /* Cleanup */
>  SelectObject(ps.hdc, hOldPen);
>  DeleteObject(hDkGrayPen);
>  DeleteObject(hBrFrame);
>  EndPaint(HWindow, &ps);

   I have added the following two lines and it seems to work OK!

   // Get The Rectangle Just Inside The Frame
   InflateRect(&rc, -1, -1);

   // Invalidate The Region
   InvalidateRegion(ps.hdc, &rc, TRUE);
n
>}

 I now have another question.  How Do I get To change the foreground,
and background colors of the edit control.  I have tried trapping the
WM_CTLCOLOR Message in the the TMainWindow::WMCtlColor function but it
doesn't seem to be working.  Here's My Code:

/*
** TMainWnd::WMCtlColor()
*/
DWORD TMainWnd::WMCtlColor(RTMessage Msg)
{
  HDC    hDC;
  WORD   wChildType;
  WORD   wChildId;

  wChildType = HIWORD(Msg.LParam);
  wChildId   = GetWindowWord(LOWORD(Msg.LParam), GWW_ID);

  UnrealizeObject(hBrushRed);
  SetBrushOrg(LOWORD(Msg.LParam), 0, 0);

  switch(wChildType)
  {
    case CTLCOLOR_EDIT:
      switch(wChildId)
      {
        case 101:
          SetTextColor(Msg.WParam, RGB(255, 0, 0));
          return (DWORD)hBrushRed;

        default:
          SetTextColor(Msg.WParam, RGB(0, 0, 255));
          return (DWORD)hBrushRed;
      };

   default:
      SetTextColor(Msg.WParam, RGB(0, 255, 0));
      return (DWORD)hBrushRed;
  };
}

Does This Look Right, I use CreateSolidBrush in TMainWnd::Setup to create
the hBrushRed, and I delete it at CloseWindow;

I don't get any compile errors, is the prototype correct?

DWORD TMainWnd::WMCtlColor(RTMessage Msg) = [WM_FIRST + WM_CTLCOLOR];

I know its getting there because I had message boxes in telling me
where I was, and I also looked at it with the debugger.  Does anybody 
have any sample code using OWL for this?????

THX
	bytor@milton.u.washington.edu
Newsgroups: comp.os.ms-windows.programmer.misc
From: dspascha@eos.ncsu.edu (DAVID SCOTT PASCHAL)
Subject: Re: buttons and scrolling
Originator: dspascha@c00083-100lez.eos.ncsu.edu
Keywords: microsoft c++ MFC
Reply-To: dspascha@eos.ncsu.edu (DAVID SCOTT PASCHAL)
Organization: North Carolina State University, Project Eos
Date: Sat, 22 Aug 1992 20:26:57 GMT


Hi.  Make your scrollable region a child window of the client window.  Then put
your buttons anywhere you want.  Sibling child windows like this shouldn't
interfere with one another.

Tschuess,
David Paschal
Newsgroups: comp.os.ms-windows.programmer.misc
From: PAULETTI@biel.be.tech.ascom.ch (Pauletti Andreas)
Subject: Question : TPW and TC++ code in the same application
Organization: Ascom Tech Ltd., Corporate Services, Division for Research 
Date: Thu, 20 Aug 1992 07:02:58 GMT
X-News-Reader: VMS NEWS 1.11

Hi

I am developing a Windows Application under TPW. I would like to use
C++ in the future. Is is possible to write some parts of den application
with OWL under TPW and some under Borland C++ (or Turbo C++) without
writing DLLs for that specific part. but still be able to call C++ routines
fro TPW and the other way round.

Write any experiences about that to me

cheers andreas pauletti
From: donc@spock.dis.cccd.edu (Don Cock)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: BC++ OWL: How do you trap the <del> key in a TEdit descendent?
Date: 12 Aug 92 15:24:24 GMT
Organization: Coast Community College District, Costa Mesa, CA

In article <1992Aug12.061741.14243@nuscc.nus.sg> ipser@solomon.technet.sg (Ed Ipser) writes:
>BC++ OWL: How do you trap the <del> key in a TEdit descendent? I can
>trap other characters with the WM_CHAR message handler but the <del>
>key slips by, mysteriously.
>

You have to trap the WM_KEYDOWN or WM_KEYUP to get the "strange" keys.

Happy trap'n, 
-- 
Don Cock                           Internet: donc@spock.dis.cccd.edu
Coast Community College District   1370 Adams Avenue
District Information Services      Costa Mesa, CA, USA  92626
Technical Support                  (714) 432-5079
"... you'll be locked into Cyberspace. Remember to do your work!" B.P. Kehoe
From: marty@cs.utexas.edu (Marty J. Sirkin)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: What is the windows call to find the video mode?
Date: 12 Aug 1992 12:50:27 -0500
Organization: CS Dept, University of Texas at Austin
NNTP-Posting-Host: predator.cs.utexas.edu

I have a very simple question (the answer to which I have been
unable to find in my very badly organized manuals).

I want, at the start of an app, to be able to determine the
video mode in which windows is running.  Specifically I 
want to know if it is a 16 or 256 (or 32K) color mode so
that I can use one of several bitmaps for the intro screen.

I have been unable to find the proper call, and I'm sure someone
out there can answer this very simply.

Thanks!
Marty Sirkin


Newsgroups: comp.os.ms-windows.programmer.misc