Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c++ > #12837 > unrolled thread

Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"

Started by"Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com>
First post2011-12-28 05:36 +0100
Last post2012-01-04 01:45 -0600
Articles 20 — 9 participants

Back to article view | Back to comp.lang.c++


Contents

  Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com> - 2011-12-28 05:36 +0100
    Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2011-12-29 19:17 +0000
    Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" RaZiel <raziel_206_@hotmail.org> - 2012-01-03 23:33 +0100
      Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-03 22:37 +0000
      Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com> - 2012-01-04 02:18 +0100
        Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Ulrich Eckhardt <ulrich.eckhardt@dominolaser.com> - 2012-01-04 15:32 +0100
          Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com> - 2012-01-04 16:40 +0100
    Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Christopher <cpisz@austin.rr.com> - 2012-01-03 17:06 -0800
      Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-04 01:16 +0000
        Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and   resources" Ian Collins <ian-news@hotmail.com> - 2012-01-04 15:20 +1300
          Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and   resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-04 02:58 +0000
            Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Miles Bader <miles@gnu.org> - 2012-01-04 12:36 +0900
        Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Paul" <pchrist<nospam>or@yahoo.co.uk> - 2012-01-04 17:49 +0000
          Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-04 18:23 +0000
            Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Paul" <pchrist<nospam>or@yahoo.co.uk> - 2012-01-04 18:48 +0000
              Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-04 19:01 +0000
                Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Paul" <pchrist<nospam>or@yahoo.co.uk> - 2012-01-04 20:56 +0000
                  Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Leigh Johnston <leigh@i42.co.uk> - 2012-01-04 21:04 +0000
                    Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" "Paul" <pchrist<nospam>or@yahoo.co.uk> - 2012-01-04 22:04 +0000
      Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources" Paavo Helde <myfirstname@osa.pri.ee> - 2012-01-04 01:45 -0600

#12837 — Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"

From"Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com>
Date2011-12-28 05:36 +0100
SubjectAnn: lesson 4 in Windows API level GUI programming "Dialogs and resources"
Message-ID<jde6bi$cjb$2@dont-email.me>
<url: 
http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>

Cheers & enjoy,

- Alf

[toc] | [next] | [standalone]


#12860

FromLeigh Johnston <leigh@i42.co.uk>
Date2011-12-29 19:17 +0000
Message-ID<oJOdnfNWfOlAIWHTnZ2dnUVZ7vednZ2d@giganews.com>
In reply to#12837
On 28/12/2011 04:36, Alf P. Steinbach wrote:
> <url:
> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>

Each "lesson" is more off-topic than the last.

/Leigh

[toc] | [prev] | [next] | [standalone]


#13046

FromRaZiel <raziel_206_@hotmail.org>
Date2012-01-03 23:33 +0100
Message-ID<jdvvms$cg1$1@speranza.aioe.org>
In reply to#12837
On 28.12.2011 05:36, Alf P. Steinbach wrote:
> <url:
> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>
>
>
> Cheers & enjoy,
>
> - Alf

Excuse my ignorance. Why does WindowSpec contain a construtor? Isn't it 
a POD?

- RaZ

[toc] | [prev] | [next] | [standalone]


#13047

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-03 22:37 +0000
Message-ID<mNadnTSH9vqAHp7SnZ2dnUVZ8radnZ2d@giganews.com>
In reply to#13046
On 03/01/2012 22:33, RaZiel wrote:
> On 28.12.2011 05:36, Alf P. Steinbach wrote:
>> <url:
>> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>
>>
>>
>>
>> Cheers & enjoy,
>>
>> - Alf
>
> Excuse my ignorance. Why does WindowSpec contain a construtor? Isn't it
> a POD?

Do you think that because 'WindowSpec' is a 'struct'?  A 'struct' 
doesn't have to be a POD just as a 'class' does not have to be a POD. 
The only difference between 'struct' and 'class' are default access 
permissions for members and inheritance ('struct' is public, 'class' is 
private).

/Leigh

[toc] | [prev] | [next] | [standalone]


#13054

From"Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com>
Date2012-01-04 02:18 +0100
Message-ID<je09d4$lub$1@dont-email.me>
In reply to#13046
On 03.01.2012 23:33, RaZiel wrote:
> On 28.12.2011 05:36, Alf P. Steinbach wrote:
>> <url:
>> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>
>
> Excuse my ignorance. Why does WindowSpec contain a construtor? Isn't it
> a POD?

Repeating the answer I posted to the same question on the blog:


<quote>
Well, WindowSpec has a constructor just for convenience. By C++98/C++03 
rules it’s therefore not a POD. By C++11 rules it is however a standard 
layout class.

I am not sure of whether it is POD by the more relaxed C++11 rules. The 
C++11 definition of POD is essentially that the class is both trivial 
and standard-layout. But the definition of “trivial” is, as I see it, 
open for interpretation, at least for pedantically formal folks. :)

Anyway, it’s just a convenience class, and since it relies on 
assumptions about memory layout, it is very system-specific (but should 
work with any Windows compiler). I started writing that code using a 
std::vector<Byte> where I serialized the data, which would have have 
yielded code that in principle could be more portable, but then I caught 
myself: hey, introducing complexity to get system portable code for 
Windows API? It was just reflex coding. So then I intentionally reworked 
and simplified that as system-specific code. :-)
</quote>


Cheers & hth.,

- Alf

[toc] | [prev] | [next] | [standalone]


#13076

FromUlrich Eckhardt <ulrich.eckhardt@dominolaser.com>
Date2012-01-04 15:32 +0100
Message-ID<eg4et8-trt.ln1@satorlaser.homedns.org>
In reply to#13054
Am 04.01.2012 02:18, schrieb Alf P. Steinbach:
> On 03.01.2012 23:33, RaZiel wrote:
>> On 28.12.2011 05:36, Alf P. Steinbach wrote:
>>> <url:
>>> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>
>>>
>>
>> Excuse my ignorance. Why does WindowSpec contain a construtor? Isn't it
>> a POD?
>
> Repeating the answer I posted to the same question on the blog:
>
>
> <quote>
> Well, WindowSpec has a constructor just for convenience. [...]
> </quote>

I think factory function are a good alternative, especially if you want 
to keep the compiler-generated default constructor and 
by-any-C++-standard POD-ness.

That said, what I find unclear is the point of single-wchar_t fields in 
that struct. I have an idea what this hack does and how it works, but 
putting that into public members seems like a bad idea to me.

Another thing I noticed on cursory reading was that you explicitly use 
wchar_t but neither MESSAGEBOXPARAMSW nor MessageBoxIndirectW().

Cheers and thank you anyway!

Uli

[toc] | [prev] | [next] | [standalone]


#13077

From"Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com>
Date2012-01-04 16:40 +0100
Message-ID<je1ru3$4ro$1@dont-email.me>
In reply to#13076
On 04.01.2012 15:32, Ulrich Eckhardt wrote:
> Am 04.01.2012 02:18, schrieb Alf P. Steinbach:
>> On 03.01.2012 23:33, RaZiel wrote:
>>> On 28.12.2011 05:36, Alf P. Steinbach wrote:
>>>> <url:
>>>> http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-resources/>
>>>>
>>>>
>>>
>>> Excuse my ignorance. Why does WindowSpec contain a construtor? Isn't it
>>> a POD?
>>
>> Repeating the answer I posted to the same question on the blog:
>>
>>
>> <quote>
>> Well, WindowSpec has a constructor just for convenience. [...]
>> </quote>
>
> I think factory function are a good alternative, especially if you want
> to keep the compiler-generated default constructor and
> by-any-C++-standard POD-ness.

Factory functions are nice for some things, but in general and in this 
case it's just more to write than simply defining a constructor.

In other words, there was no particular reason to use a factory function.



> That said, what I find unclear is the point of single-wchar_t fields in
> that struct. I have an idea what this hack does and how it works, but
> putting that into public members seems like a bad idea to me.

They represent the terminating nulls of null-terminated strings.


> Another thing I noticed on cursory reading was that you explicitly use
> wchar_t but neither MESSAGEBOXPARAMSW nor MessageBoxIndirectW().

[windows.h] does not IMHO define any better, more readable name for 
`wchar_t`.

However, [windows.h] does define e.g. MSGBOXPARAMS as a more readable 
alternative for MSGBOXPARAMSW, and it is not only more readable but also 
more easy to look up in the documentation (e.g., right-click and google).

In modern Windows programming there is no practical reason to reserve 
that name for places where it might work to instead have it defined as 
MSGBOXPARAMSA, since (one just ensures that) it will never be defined as 
anything but MSGBOXPARAMSW.


> Cheers and thank you anyway!
>
> Uli

Cheers,

- ALf

[toc] | [prev] | [next] | [standalone]


#13051

FromChristopher <cpisz@austin.rr.com>
Date2012-01-03 17:06 -0800
Message-ID<12fef322-66b8-4152-8728-236eb8c75511@n6g2000vbz.googlegroups.com>
In reply to#12837
On Dec 27 2011, 10:36 pm, "Alf P. Steinbach" <alf.p.steinbach
+use...@gmail.com> wrote:
> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>
> Cheers & enjoy,
>
> - Alf

I don't understand these posts anymore. I was under the impression
that Alf usually complained about some short coming of Windows as it
relates to C++ and Leigh would argue back, triggering an argument from
Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
proponent and Leight is not? I need to understand the characters in
this drama.

[toc] | [prev] | [next] | [standalone]


#13053

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-04 01:16 +0000
Message-ID<v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com>
In reply to#13051
On 04/01/2012 01:06, Christopher wrote:
> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
> +use...@gmail.com>  wrote:
>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>
>> Cheers&  enjoy,
>>
>> - Alf
>
> I don't understand these posts anymore. I was under the impression
> that Alf usually complained about some short coming of Windows as it
> relates to C++ and Leigh would argue back, triggering an argument from
> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
> proponent and Leight is not? I need to understand the characters in
> this drama.

Me?

I think Windows is a fine OS but Microsoft's Windows C++ support not so 
much; I didn't used to mind MFC but I have recently decided that it 
really is a bag of shite and as a result of this and for other reasons I 
am creating my own cross-platform C++ GUI lib which you can check out at 
http://neogfx.org if interested (work in progress, hopefully out in 2012).

/Leigh

[toc] | [prev] | [next] | [standalone]


#13057 — Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"

FromIan Collins <ian-news@hotmail.com>
Date2012-01-04 15:20 +1300
SubjectRe: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"
Message-ID<9mhrbnFpeqU4@mid.individual.net>
In reply to#13053
On 01/ 4/12 02:16 PM, Leigh Johnston wrote:
> On 04/01/2012 01:06, Christopher wrote:
>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>> +use...@gmail.com>   wrote:
>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>
>>> Cheers&   enjoy,
>>>
>>> - Alf
>>
>> I don't understand these posts anymore. I was under the impression
>> that Alf usually complained about some short coming of Windows as it
>> relates to C++ and Leigh would argue back, triggering an argument from
>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>> proponent and Leight is not? I need to understand the characters in
>> this drama.
>
> Me?
>
> I think Windows is a fine OS but Microsoft's Windows C++ support not so
> much; I didn't used to mind MFC but I have recently decided that it
> really is a bag of shite and as a result of this and for other reasons I
> am creating my own cross-platform C++ GUI lib which you can check out at
> http://neogfx.org if interested (work in progress, hopefully out in 2012).

Another one?  Aren't there enough already?

-- 
Ian Collins

[toc] | [prev] | [next] | [standalone]


#13061 — Re: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-04 02:58 +0000
SubjectRe: Ann: lesson 4 in Windows API level GUI programming "Dialogs and resources"
Message-ID<0sKdnZvz467xXZ7SnZ2dnUVZ7vOdnZ2d@giganews.com>
In reply to#13057
On 04/01/2012 02:20, Ian Collins wrote:
> On 01/ 4/12 02:16 PM, Leigh Johnston wrote:
>> On 04/01/2012 01:06, Christopher wrote:
>>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>>> +use...@gmail.com> wrote:
>>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>>
>>>>
>>>> Cheers& enjoy,
>>>>
>>>> - Alf
>>>
>>> I don't understand these posts anymore. I was under the impression
>>> that Alf usually complained about some short coming of Windows as it
>>> relates to C++ and Leigh would argue back, triggering an argument from
>>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>>> proponent and Leight is not? I need to understand the characters in
>>> this drama.
>>
>> Me?
>>
>> I think Windows is a fine OS but Microsoft's Windows C++ support not so
>> much; I didn't used to mind MFC but I have recently decided that it
>> really is a bag of shite and as a result of this and for other reasons I
>> am creating my own cross-platform C++ GUI lib which you can check out at
>> http://neogfx.org if interested (work in progress, hopefully out in
>> 2012).
>
> Another one? Aren't there enough already?

There will never be enough.

/Leigh

[toc] | [prev] | [next] | [standalone]


#13062

FromMiles Bader <miles@gnu.org>
Date2012-01-04 12:36 +0900
Message-ID<8739bw16ly.fsf@catnip.gol.com>
In reply to#13061
Leigh Johnston <leigh@i42.co.uk> writes:
>>> I am creating my own cross-platform C++ GUI lib which you can check
>>> out at http://neogfx.org if interested.
>>
>> Another one? Aren't there enough already?
>
> There will never be enough.

Maybe one of these days, somebody will finally get it right...

-miles

-- 
History, n. An account mostly false, of events mostly unimportant, which are
brought about by rulers mostly knaves, and soldiers mostly fools.

[toc] | [prev] | [next] | [standalone]


#13081

From"Paul" <pchrist<nospam>or@yahoo.co.uk>
Date2012-01-04 17:49 +0000
Message-ID<je23fg$tjt$1@adenine.netfront.net>
In reply to#13053
"Leigh Johnston" <leigh@i42.co.uk> wrote in message 
news:v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com...
> On 04/01/2012 01:06, Christopher wrote:
>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>> +use...@gmail.com>  wrote:
>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>
>>> Cheers&  enjoy,
>>>
>>> - Alf
>>
>> I don't understand these posts anymore. I was under the impression
>> that Alf usually complained about some short coming of Windows as it
>> relates to C++ and Leigh would argue back, triggering an argument from
>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>> proponent and Leight is not? I need to understand the characters in
>> this drama.
>
> Me?
>
> I think Windows is a fine OS but Microsoft's Windows C++ support not so 
> much; I didn't used to mind MFC but I have recently decided that it really 
> is a bag of shite and as a result of this and for other reasons I am 
> creating my own cross-platform C++ GUI lib which you can check out at 
> http://neogfx.org if interested (work in progress, hopefully out in 2012).
>

That xml is horrible.Don't use attributes for data.


I notice you don't give a proper example of source code with instructions of 
how to compile/link. What is that code some kind of mixed XML and C++ 



--- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---

[toc] | [prev] | [next] | [standalone]


#13082

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-04 18:23 +0000
Message-ID<CdmdnfjMJYObBJnSnZ2dnUVZ8jidnZ2d@giganews.com>
In reply to#13081
On 04/01/2012 17:49, Paul <pchrist wrote:
> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
> news:v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com...
>> On 04/01/2012 01:06, Christopher wrote:
>>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>>> +use...@gmail.com>   wrote:
>>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>>
>>>> Cheers&   enjoy,
>>>>
>>>> - Alf
>>>
>>> I don't understand these posts anymore. I was under the impression
>>> that Alf usually complained about some short coming of Windows as it
>>> relates to C++ and Leigh would argue back, triggering an argument from
>>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>>> proponent and Leight is not? I need to understand the characters in
>>> this drama.
>>
>> Me?
>>
>> I think Windows is a fine OS but Microsoft's Windows C++ support not so
>> much; I didn't used to mind MFC but I have recently decided that it really
>> is a bag of shite and as a result of this and for other reasons I am
>> creating my own cross-platform C++ GUI lib which you can check out at
>> http://neogfx.org if interested (work in progress, hopefully out in 2012).
>>
>
> That xml is horrible.Don't use attributes for data.

Don't use XML attributes for data?  Are you crazy?

> I notice you don't give a proper example of source code with instructions of
> how to compile/link. What is that code some kind of mixed XML and C++

Instructions on how to use the library are not yet available as the 
library is still in development.

No it is not mixed XML and C++; the XML is in a resource file which is 
compiled separately to the C++ by my resource compiler.

/Leigh

[toc] | [prev] | [next] | [standalone]


#13083

From"Paul" <pchrist<nospam>or@yahoo.co.uk>
Date2012-01-04 18:48 +0000
Message-ID<je26u6$103v$1@adenine.netfront.net>
In reply to#13082
"Leigh Johnston" <leigh@i42.co.uk> wrote in message 
news:CdmdnfjMJYObBJnSnZ2dnUVZ8jidnZ2d@giganews.com...
> On 04/01/2012 17:49, Paul <pchrist wrote:
>> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
>> news:v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com...
>>> On 04/01/2012 01:06, Christopher wrote:
>>>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>>>> +use...@gmail.com>   wrote:
>>>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>>>
>>>>> Cheers&   enjoy,
>>>>>
>>>>> - Alf
>>>>
>>>> I don't understand these posts anymore. I was under the impression
>>>> that Alf usually complained about some short coming of Windows as it
>>>> relates to C++ and Leigh would argue back, triggering an argument from
>>>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>>>> proponent and Leight is not? I need to understand the characters in
>>>> this drama.
>>>
>>> Me?
>>>
>>> I think Windows is a fine OS but Microsoft's Windows C++ support not so
>>> much; I didn't used to mind MFC but I have recently decided that it 
>>> really
>>> is a bag of shite and as a result of this and for other reasons I am
>>> creating my own cross-platform C++ GUI lib which you can check out at
>>> http://neogfx.org if interested (work in progress, hopefully out in 
>>> 2012).
>>>
>>
>> That xml is horrible.Don't use attributes for data.
>
> Don't use XML attributes for data?  Are you crazy?

The comment was related to your xml coding style. Its not right nor wrong 
its just a matter of taste as expalined here:
http://www.w3schools.com/xml/xml_attributes.asp

Your XML resembles the "Don't end up like this" example shown under the 
heading "Avoid XML Attributes.
Like I said it's horrible XML.

>
>> I notice you don't give a proper example of source code with instructions 
>> of
>> how to compile/link. What is that code some kind of mixed XML and C++
>
> Instructions on how to use the library are not yet available as the 
> library is still in development.
>
> No it is not mixed XML and C++; the XML is in a resource file which is 
> compiled separately to the C++ by my resource compiler.
>

So if I write a windows program which usually has the entry point winMain 
function, your GUI library would replace the whole program entry point 
function with a main fucntion?
And your GUI library also controls the msgLoop?










--- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---

[toc] | [prev] | [next] | [standalone]


#13084

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-04 19:01 +0000
Message-ID<PJCdnfZfeuqJP5nSnZ2dnUVZ8kqdnZ2d@giganews.com>
In reply to#13083
On 04/01/2012 18:48, Paul <pchrist wrote:
> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
> news:CdmdnfjMJYObBJnSnZ2dnUVZ8jidnZ2d@giganews.com...
>> On 04/01/2012 17:49, Paul<pchrist wrote:
>>> "Leigh Johnston"<leigh@i42.co.uk>   wrote in message
>>> news:v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com...
>>>> On 04/01/2012 01:06, Christopher wrote:
>>>>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>>>>> +use...@gmail.com>    wrote:
>>>>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>>>>
>>>>>> Cheers&    enjoy,
>>>>>>
>>>>>> - Alf
>>>>>
>>>>> I don't understand these posts anymore. I was under the impression
>>>>> that Alf usually complained about some short coming of Windows as it
>>>>> relates to C++ and Leigh would argue back, triggering an argument from
>>>>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>>>>> proponent and Leight is not? I need to understand the characters in
>>>>> this drama.
>>>>
>>>> Me?
>>>>
>>>> I think Windows is a fine OS but Microsoft's Windows C++ support not so
>>>> much; I didn't used to mind MFC but I have recently decided that it
>>>> really
>>>> is a bag of shite and as a result of this and for other reasons I am
>>>> creating my own cross-platform C++ GUI lib which you can check out at
>>>> http://neogfx.org if interested (work in progress, hopefully out in
>>>> 2012).
>>>>
>>>
>>> That xml is horrible.Don't use attributes for data.
>>
>> Don't use XML attributes for data?  Are you crazy?
>
> The comment was related to your xml coding style. Its not right nor wrong
> its just a matter of taste as expalined here:
> http://www.w3schools.com/xml/xml_attributes.asp
>
> Your XML resembles the "Don't end up like this" example shown under the
> heading "Avoid XML Attributes.
> Like I said it's horrible XML.

You do not know what you are talking about irrespective of what some 
random website says; there is nothing wrong with the XML.  I am well 
aware of when to use attributes and when to use elements.

>
>>
>>> I notice you don't give a proper example of source code with instructions
>>> of
>>> how to compile/link. What is that code some kind of mixed XML and C++
>>
>> Instructions on how to use the library are not yet available as the
>> library is still in development.
>>
>> No it is not mixed XML and C++; the XML is in a resource file which is
>> compiled separately to the C++ by my resource compiler.
>>
>
> So if I write a windows program which usually has the entry point winMain
> function, your GUI library would replace the whole program entry point
> function with a main fucntion?

Yes as the example illustrates except you wouldn't be writing a "Windows 
program" you would be writing a "neogfx program".

> And your GUI library also controls the msgLoop?

The Windows version of neogfx provides the message loop yes.

/Leigh

[toc] | [prev] | [next] | [standalone]


#13091

From"Paul" <pchrist<nospam>or@yahoo.co.uk>
Date2012-01-04 20:56 +0000
Message-ID<je2edv$15p0$1@adenine.netfront.net>
In reply to#13084
"Leigh Johnston" <leigh@i42.co.uk> wrote in message 
news:PJCdnfZfeuqJP5nSnZ2dnUVZ8kqdnZ2d@giganews.com...
> On 04/01/2012 18:48, Paul <pchrist wrote:
>> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
>> news:CdmdnfjMJYObBJnSnZ2dnUVZ8jidnZ2d@giganews.com...
>>> On 04/01/2012 17:49, Paul<pchrist wrote:
>>>> "Leigh Johnston"<leigh@i42.co.uk>   wrote in message
>>>> news:v8CdnTN_s7wUNZ7SnZ2dnUVZ8rWdnZ2d@giganews.com...
>>>>> On 04/01/2012 01:06, Christopher wrote:
>>>>>> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach"<alf.p.steinbach
>>>>>> +use...@gmail.com>    wrote:
>>>>>>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-reso...>
>>>>>>>
>>>>>>> Cheers&    enjoy,
>>>>>>>
>>>>>>> - Alf
>>>>>>
>>>>>> I don't understand these posts anymore. I was under the impression
>>>>>> that Alf usually complained about some short coming of Windows as it
>>>>>> relates to C++ and Leigh would argue back, triggering an argument 
>>>>>> from
>>>>>> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
>>>>>> proponent and Leight is not? I need to understand the characters in
>>>>>> this drama.
>>>>>
>>>>> Me?
>>>>>
>>>>> I think Windows is a fine OS but Microsoft's Windows C++ support not 
>>>>> so
>>>>> much; I didn't used to mind MFC but I have recently decided that it
>>>>> really
>>>>> is a bag of shite and as a result of this and for other reasons I am
>>>>> creating my own cross-platform C++ GUI lib which you can check out at
>>>>> http://neogfx.org if interested (work in progress, hopefully out in
>>>>> 2012).
>>>>>
>>>>
>>>> That xml is horrible.Don't use attributes for data.
>>>
>>> Don't use XML attributes for data?  Are you crazy?
>>
>> The comment was related to your xml coding style. Its not right nor wrong
>> its just a matter of taste as expalined here:
>> http://www.w3schools.com/xml/xml_attributes.asp
>>
>> Your XML resembles the "Don't end up like this" example shown under the
>> heading "Avoid XML Attributes.
>> Like I said it's horrible XML.
>
> You do not know what you are talking about irrespective of what some 
> random website says; there is nothing wrong with the XML.  I am well aware 
> of when to use attributes and when to use elements.
>
Ok if you say so.
>>
>>>
>>>> I notice you don't give a proper example of source code with 
>>>> instructions
>>>> of
>>>> how to compile/link. What is that code some kind of mixed XML and C++
>>>
>>> Instructions on how to use the library are not yet available as the
>>> library is still in development.
>>>
>>> No it is not mixed XML and C++; the XML is in a resource file which is
>>> compiled separately to the C++ by my resource compiler.
>>>
>>
>> So if I write a windows program which usually has the entry point winMain
>> function, your GUI library would replace the whole program entry point
>> function with a main fucntion?
>
> Yes as the example illustrates except you wouldn't be writing a "Windows 
> program" you would be writing a "neogfx program".
>
>> And your GUI library also controls the msgLoop?
>
> The Windows version of neogfx provides the message loop yes.
>
So if  someone wanted to use a windows service,  such as a timer for 
example, and accept incoming events from it. Would this be possible from 
within your neogfx program? 



--- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---

[toc] | [prev] | [next] | [standalone]


#13092

FromLeigh Johnston <leigh@i42.co.uk>
Date2012-01-04 21:04 +0000
Message-ID<9fednQV0w5JWI5nSnZ2dnUVZ8oOdnZ2d@giganews.com>
In reply to#13091
On 04/01/2012 20:56, Paul <pchrist wrote:
> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
> news:PJCdnfZfeuqJP5nSnZ2dnUVZ8kqdnZ2d@giganews.com...
>> On 04/01/2012 18:48, Paul<pchrist wrote:
[snip]
>>> And your GUI library also controls the msgLoop?
>>
>> The Windows version of neogfx provides the message loop yes.
>>
> So if  someone wanted to use a windows service,  such as a timer for
> example, and accept incoming events from it. Would this be possible from
> within your neogfx program?

My library provides its own timers. The goal is to provide a library 
that allows the programmer to write as little platform specific code as 
possible.  The Windows specific message loop is hidden from the programmer.

/Leigh

[toc] | [prev] | [next] | [standalone]


#13096

From"Paul" <pchrist<nospam>or@yahoo.co.uk>
Date2012-01-04 22:04 +0000
Message-ID<je2ie0$189s$1@adenine.netfront.net>
In reply to#13092
"Leigh Johnston" <leigh@i42.co.uk> wrote in message 
news:9fednQV0w5JWI5nSnZ2dnUVZ8oOdnZ2d@giganews.com...
> On 04/01/2012 20:56, Paul <pchrist wrote:
>> "Leigh Johnston"<leigh@i42.co.uk>  wrote in message
>> news:PJCdnfZfeuqJP5nSnZ2dnUVZ8kqdnZ2d@giganews.com...
>>> On 04/01/2012 18:48, Paul<pchrist wrote:
> [snip]
>>>> And your GUI library also controls the msgLoop?
>>>
>>> The Windows version of neogfx provides the message loop yes.
>>>
>> So if  someone wanted to use a windows service,  such as a timer for
>> example, and accept incoming events from it. Would this be possible from
>> within your neogfx program?
>
> My library provides its own timers. The goal is to provide a library that 
> allows the programmer to write as little platform specific code as 
> possible.  The Windows specific message loop is hidden from the 
> programmer.
>

Well err good luck with that.



--- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---

[toc] | [prev] | [next] | [standalone]


#13066

FromPaavo Helde <myfirstname@osa.pri.ee>
Date2012-01-04 01:45 -0600
Message-ID<Xns9FD063470493Cmyfirstnameosapriee@216.196.109.131>
In reply to#13051
Christopher <cpisz@austin.rr.com> wrote in
news:12fef322-66b8-4152-8728-236eb8c75511@n6g2000vbz.googlegroups.com: 

> On Dec 27 2011, 10:36 pm, "Alf P. Steinbach" <alf.p.steinbach
> +use...@gmail.com> wrote:
>> <url:http://learnwinapi.wordpress.com/2011/12/28/lesson-4-dialogs-and-
>> res 
> o...>
>>
>> Cheers & enjoy,
>>
>> - Alf
> 
> I don't understand these posts anymore. I was under the impression
> that Alf usually complained about some short coming of Windows as it
> relates to C++ and Leigh would argue back, triggering an argument from
> Alf, and etc. etc. Did I get it mixed up and Alf is the Windows
> proponent and Leight is not? I need to understand the characters in
> this drama.

I think there is no drama, this is not an OS advocacy group. In a 
technical group, Windows is a tool for getting something done, not 
something to love or hate. The discussion is about how to use this tool 
better.

Alf wants to be able to write robust and portable style Windows GUI code 
without resorting to any "black magic" usually associated with Windows 
GUI programming (generated code using obscure macros, wysiwyg dialog 
editors, hidden message loops etc.). Leigh wants to get all rules 
followed by 100%, which is good for technical details, but does not work 
so well with people. At least for technical parts their goals have some 
overlap as far as I can see.

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.c++


csiph-web