14 Replies - 1973 Views - Last Post: 31 August 2016 - 12:51 PM

#1 Tyr4el  Icon User is offline

  • D.I.C Addict

Reputation: 23
  • View blog
  • Posts: 507
  • Joined: 24-October 14

Curious - What are the GUIs Written In For C Programs?

Posted 13 January 2016 - 06:05 PM

So I'm just starting school again finally to get my IT degree and I'm taking an Intro to Programming class. We are using C. I know C is used for a lot including games and other software applications. But my question is how are the GUIs written and coded if not done in C (I read somewhere it's super hard to code a GUI in C and usually not done)?

Thanks and I'm sure I'll be posting more again!


Sent from my iPhone using Tapatalk

Is This A Good Question/Topic? 0
  • +

Replies To: Curious - What are the GUIs Written In For C Programs?

#2 Skydiver  Icon User is online

  • Code herder
  • member icon

Reputation: 5928
  • View blog
  • Posts: 20,267
  • Joined: 05-May 12

Re: Curious - What are the GUIs Written In For C Programs?

Posted 13 January 2016 - 07:02 PM

Where did you hear that? Windows and NT wee originally written in C. All the Office apps were originally written in C. Despite a major refactoring, portions of Visual Studio is still in C.

Anyway, to answer your question (that seems to be the opposite of what your topic title is asking), programs not written in C still will make either API calls to the OS, or use libraries that will make the OS API calls for them.
Was This Post Helpful? 1
  • +
  • -

#3 Tyr4el  Icon User is offline

  • D.I.C Addict

Reputation: 23
  • View blog
  • Posts: 507
  • Joined: 24-October 14

Re: Curious - What are the GUIs Written In For C Programs?

Posted 13 January 2016 - 07:14 PM

Interesting. I read it in a Stack Exchange post. Maybe I misunderstood the post but a lot of the contributors were saying that it's easier or better to create the GUI in Python or Java.

But that aside, you're saying that they can be created in C? That's pretty cool. I was just curious. And still out of curiosity, what are these Windows Forms in my Visual Studio 2015? I'm not looking currently but there are several options I believe with one of them being a new standard in Windows 8 I think. Are those used to create UIs for some applications? Like if I wanted to make a small calculator app or something.
Was This Post Helpful? 0
  • +
  • -

#4 ndc85430  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 614
  • Posts: 2,590
  • Joined: 13-June 14

Re: Curious - What are the GUIs Written In For C Programs?

Posted 13 January 2016 - 11:43 PM

There are certainly GUI libraries written in C - GTK+ is a prominent one (at least on *NIX).

This post has been edited by ndc85430: 13 January 2016 - 11:47 PM

Was This Post Helpful? 0
  • +
  • -

#5 jjl  Icon User is offline

  • Engineer
  • member icon

Reputation: 1270
  • View blog
  • Posts: 4,997
  • Joined: 09-June 09

Re: Curious - What are the GUIs Written In For C Programs?

Posted 14 January 2016 - 09:56 AM

I typically do my GUI development using Qt (C++ extension)

http://www.qt.io/
Was This Post Helpful? 0
  • +
  • -

#6 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6560
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Curious - What are the GUIs Written In For C Programs?

Posted 14 January 2016 - 11:29 AM

For Microsoft Windows, if you're using the Windows API, the language (in my experience) is irrelevant. One can write Windows programs using the API written in Assembly, C/C++, or VB, & using DLL's you can even mix the languages. But keep in mind that my experience with development in Windows stopped in XP.
Was This Post Helpful? 0
  • +
  • -

#7 vividexstance  Icon User is offline

  • Tiocfaidh ár lá
  • member icon

Reputation: 792
  • View blog
  • Posts: 2,870
  • Joined: 31-December 10

Re: Curious - What are the GUIs Written In For C Programs?

Posted 16 January 2016 - 08:27 AM

I second jjl, I really like the Qt IDE and the cross-platform GUI toolkit they provide. They also have excellent documentation including numerous examples.

In the end, I like using a plain old notepad, like gEdit on linux, which has some nice plugins for developing, but I also like being able to see the whole compile process so I can tell what's going wrong and where.
Was This Post Helpful? 0
  • +
  • -

#8 freedom_doc  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 6
  • Joined: 16-January 16

Re: Curious - What are the GUIs Written In For C Programs?

Posted 16 January 2016 - 07:43 PM

All serious OS's (operating systems) have been written in C for quite some time, since UNIX. C is the only high level language with low level enough constructs to allow bare metal programming that is needed in an OS. Of course, C++ also has this since it supports C, but so far as I know, no OS writer wants to use C++, period.
Was This Post Helpful? 0
  • +
  • -

#9 vividexstance  Icon User is offline

  • Tiocfaidh ár lá
  • member icon

Reputation: 792
  • View blog
  • Posts: 2,870
  • Joined: 31-December 10

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 08:06 AM

And how many OS "writers" do you know?
Was This Post Helpful? 0
  • +
  • -

#10 freedom_doc  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 6
  • Joined: 16-January 16

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 11:08 AM

View Postvividexstance, on 17 January 2016 - 08:06 AM, said:

And how many OS "writers" do you know?

Not that many, but I do know that every OS (of any note) since UNIX has BEEN written in C (with an assembly kernel). I have read of OS writers talking about how they would never write it in C++; so far that has held up.

Now some toy OS's may have been done in almost any language but you generally never hear much from those. Minix and Linux started out that way but both were done in C (except for the parts that HAD to be done in ASM -- usually about 5%).
Was This Post Helpful? 0
  • +
  • -

#11 vividexstance  Icon User is offline

  • Tiocfaidh ár lá
  • member icon

Reputation: 792
  • View blog
  • Posts: 2,870
  • Joined: 31-December 10

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 11:26 AM

No offense, but without evidence or backup, I feel you're talking out of your arse. The GNU C++ compiler is written in C++, so why couldn't an OS be?

Also, C++ supports many programming idioms and techniques that C just cannot. So why wouldn't someone want to use C++ over C?

*EDIT*: Links might back up your claim, but you haven't posted any.

This post has been edited by vividexstance: 17 January 2016 - 11:27 AM

Was This Post Helpful? 0
  • +
  • -

#12 Skydiver  Icon User is online

  • Code herder
  • member icon

Reputation: 5928
  • View blog
  • Posts: 20,267
  • Joined: 05-May 12

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 11:52 AM

View Postfreedom_doc, on 17 January 2016 - 01:08 PM, said:

View Postvividexstance, on 17 January 2016 - 08:06 AM, said:

And how many OS "writers" do you know?

Not that many, but I do know that every OS (of any note) since UNIX has BEEN written in C (with an assembly kernel). I have read of OS writers talking about how they would never write it in C++; so far that has held up.

Perhaps not write UNIX in C++, but that does not presume that other OSes.

C and C++ will both get compiled down to machine language. Modern compilers can generate very efficient machine language from both C and C++. It's just a matter of how one writes the code. Just like it is possible to write efficient C# code that is comparable to C/C++ performance, it is possible to write C++ code that is very efficient.

I suspect that the preference for C over C++, is that one can "cheat" and play games with types without being explicit about those events of cheating as one would be forced to do in C++.
Was This Post Helpful? 1
  • +
  • -

#13 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6560
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 12:26 PM

I would never categorize OSes by "Serious" & "Toy", as an OS is defined (at least my understanding) to boot the MBR to the point of taking instruction, requesting processing via the CPU, & getting a result. So software is measurable as binary, it either IS or it IS NOT an OS. What I would categorize OSes by is commercial, & non-commercial. But that's just me, & I'm not sure why any of this OS talk is relevant when the question in the original post is with regards to a GUI.
Was This Post Helpful? 0
  • +
  • -

#14 freedom_doc  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 6
  • Joined: 16-January 16

Re: Curious - What are the GUIs Written In For C Programs?

Posted 17 January 2016 - 12:56 PM

As far as pushing the discussion to OS's, that was me, I mistook the poster's mention of GUI to mean an OS that uses a GUI primarily. So, don't worry about it.
Was This Post Helpful? 0
  • +
  • -

#15 CaEngineer  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 31
  • Joined: 31-July 15

Re: Curious - What are the GUIs Written In For C Programs?

Posted 31 August 2016 - 12:51 PM

Mostly in C# with Visual Studio.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1