Article View: borland.public.cppbuilder.nativeapi
Article #13537Re: Get style of a button
From: Bob Gonder
Date: Wed, 08 Oct 2003 18:24
Date: Wed, 08 Oct 2003 18:24
28 lines
1733 bytes
1733 bytes
husonov wrote:
> BS_PUSHBUTTON = 0;
> BS_DEFPUSHBUTTON = 1;
> BS_CHECKBOX = 2;
> BS_AUTOCHECKBOX = 3;
> BS_RADIOBUTTON = 4;
> BS_3STATE = 5;
> BS_AUTO3STATE = 6;
> BS_GROUPBOX = 7;
> BS_USERBUTTON = 8;
> BS_AUTORADIOBUTTON = 9;
> BS_OWNERDRAW = 11;
>
>How can I know mathematically/logically that someone had specified
>BS_DEFPUSHBUTTON, BS_CHECKBOX, BS_RADIOBUTTON, etc. in the dwStyle
>parameter?
Test in decending order:
if( (Flag & BS_OWNERDRAW)==BS_OWNERDRAW )
{ report( "BS_OWNERDRAW" );
Flag ^= BS_OWNERDRAW; /* turn off the 8,2,1 bits */
}
if( (Flag & BS_AUTORADIOBUTTON) == BS_AUTORADIOBUTTON )
{ report("BS_AUTORADIOBUTTON");
Flag ^= BS_AUTORADIOBUTTON;
}
etc....
Technical Details
Message-ID:
<5al8ovcueb32g251ckdinjo6lsb70ah8ms@4ax.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<3f83ae37@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,f25c939140529f26 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2003-10-08 11:44:43 PST From: Bob Gonder <notbg@notmindspring.invalid> Newsgroups: borland.public.cppbuilder.nativeapi Subject: Re: Get style of a button Date: Wed, 08 Oct 2003 11:24:11 -0700 Organization: MindSpring Enterprises, Inc. Reply-To: notbg@notmindspring.invalid Message-ID: <5al8ovcueb32g251ckdinjo6lsb70ah8ms@4ax.com> References: <3f83ae37@newsgroups.borland.com> X-Newsreader: Forte Agent 1.91/32.564 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 67.31.165.186 X-Trace: newsgroups.borland.com 1065637449 67.31.165.186 (8 Oct 2003 11:24:09 -0700) Lines: 31 Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail