Re: Must pixmap object be global and defined to = NULL initially??? Any more elegant solution?



Chris Seberino <seberino spawar navy mil> writes:
> 
> Why must GdkPixmap* pixmap = NULL be among
> first lines of program??? Is there anyway to avoid
> having this be global?? What about in C++??
> I'm using C bindings (normal GTK+ in C++) not GTK++/GTKmm.

Sure, you can put it anywhere you want, where you'd put any other
variable.

> I like elegance and global variables don't seem too elegant.
> Correct me if I'm wrong.

How do you avoid globals for other variables? Avoid them the same way
here.

Havoc





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]