Go Job Hunting at the LQ Job Marketplace
Go Back > Forums > Linux Forums > Linux - Desktop
User Name
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.


  Search this Thread
Old 10-23-2006, 04:45 AM   #1
LQ Newbie
Registered: Apr 2006
Location: India
Posts: 9

Rep: Reputation: 0
GTK code uses pointer for structs and not normal instances why?


I was goinf through the GTK code and saw that GTK code uses pointer for structs and not normal instances of the same structs...

why could this be so?
My take is that they wanted to use just one variable name and they can easily initialise the pointer to that struct type .

whereas if they used just an instance of the struct, they wd have to create a new instance evry time they needed a new variable ...

am i on the right direction?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Suggestion: put [CODE] button on normal editor theNbomr LQ Suggestions & Feedback 4 09-22-2006 12:03 PM
C code outputs pointer references not values caged Programming 2 06-13-2005 05:24 PM
Structs for a Text Editor in GTK/C MicahCarrick Programming 2 05-16-2005 08:22 AM
Why this GTK example code compile error? searun Programming 1 07-22-2004 08:21 AM

All times are GMT -5. The time now is 06:59 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration