QT for OS programming

Hello everyone and Merry late Christmas!

So I have some beginner questions.

First, I'm learning c++ in order to reach my goal of being a programmer on a operating system. (Windows, OS X, android core, etc)

So should I stay away from QT? I ask because I noticed some differences on it. For example Qstrings vs regular strings. Wouldn't it be better to have most practice with regular strings then Qstrings for what I want to do?

Let's say I end up working at Apple on OSX (wishful thinking I know) I strongly doubt they use Qstrings. I'm sure they would use the normal c strings or c++ strings. Right?

Guess what I'm trying to ask is, is qt worth learning for getting a job at a corporate company? Or should I stick with the libraries included with c++

Also another question that may sound stupid but it's about memory management.

Do I need to delete strings after I'm done using them? If so how do I do this?

If I'm reading a file line by line using something like getline(myfile, stringname)
Do I need to delete the string at the end of every loop?

Sorry I'm be mostly on Python since the beginning and I never had to worry about memory management.
> So should I stay away from QT?

Yes, while you are trying to learn C++. Qt has far too many C++ anti-patterns.


> is qt worth learning for getting a job at a corporate company?
> Or should I stick with the libraries included with c++

Learn standard, idiomatic C++ first.

Knowledge of Qt may be a plus point in a few set ups.
Lack of knowledge of standard C++ would be a big minus everywhere (everywhere where C++ is the core programming language).


> Do I need to delete strings after I'm done using them? If so how do I do this?
> If I'm reading a file line by line using something like getline(myfile, stringname)
> Do I need to delete the string at the end of every loop?

No.

1
2
3
4
5
std::string line ; // automatic storage duration
while( std::getline( my_file, line )
{
     // do something with line
} 



> I'm be mostly on Python since the beginning and I never had to worry about memory management.

You don't have to worry about memory management in C++ either (not for several months, till you are ready to start writing low-level code).
is qt worth learning for getting a job at a corporate company?


It depends on the company. I am not sure what the most popular framework for C++ is.

I don't know where you live but I guess/hope that there is some kind of job centre around where you could get some career advice.
Operating System work is serious business. You're going to already have some sort of real world experience if an employer looks at you for developing those complex systems. I highly doubt there's an entry level job in that category.
I highly doubt there's an entry level job in that category.

That is a good point. I would also add that how well someones knows C++. or any other language for that matter, is a much lower priority than understanding how the operating system itself works. I found this book more helpful in my OS class then the text book that went with the class:
http://www.amazon.com/Understanding-Operating-Systems-Ann-McHoes/dp/128509655X

A good source for information about creating operating systems is:
http://wiki.osdev.org/Main_Page

If you want to get real low level, assembly, this is an interesting set of lectures:
https://www.youtube.com/watch?v=YvZhgRO7hL4



Topic archived. No new replies allowed.