LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

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

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


Hi

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?
 
  


Reply


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 01:03 PM
C code outputs pointer references not values caged Programming 2 06-13-2005 06:24 PM
Structs for a Text Editor in GTK/C MicahCarrick Programming 2 05-16-2005 09:22 AM
Why this GTK example code compile error? searun Programming 1 07-22-2004 09:21 AM


All times are GMT -5. The time now is 05:51 AM.

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