LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   creating a simple GTK-based front-end (https://www.linuxquestions.org/questions/programming-9/creating-a-simple-gtk-based-front-end-321769/)

bpk 05-09-2005 05:15 PM

creating a simple GTK-based front-end
 
Hey all, Got a few intro questions...

I find myself systematically making encoded copies (mp3, ogg and flac) of raw PCM / wav files and im sick of hacking to open up a terminal and cutting and pasting my encode commands (they're always the same)... don't care about comment tags (yet)

I'd like to build against GTK because I assume IDE's like Glade would really help me make this project easy (im mostly a CLI scripter for sysadmin duties, also know a little php). I also use Gnome (Ubuntu's release) which I'm very happy (and proud) to use. It's clean mmmm, and I hate the letter K... jk.

Anyway, All i'd like to so is create a GUI app that is nothing more then a front-end to my three back-end command line tools, lame, oggenc and flac.

Any suggestions or tips on where to start? Im mor econcerned with getting this particular project put together then learning all the bells and whistles of coding, that'll come with time.

Thanks!

mandeltuete 05-11-2005 06:32 AM

check out http://www.gtk.org/tutorial/
it will get you started quite quickly. for example read chapter 1-4 and chapter five packing with boxes. you should be able to do some input and output stuff then.
if you don't know yet, look into 'man popen' to execute your command and get the output (if you intend to code in c, however, there are also several gtk frontends for other languages)

hth

bpk 05-12-2005 08:33 PM

Thank you very much for your reply.

Im not sure where to start really and if I take it on as "Im going to learn C" , personally, thats to broad of a goal and the chances of me forgetting/getting lazy are much higher then if I were to take on coding based on a product I'd like to make.

I figure it wont be to hard as all im realyl doing is acting as a front-end. I think it's a good first project but extremelely hard. I come from a graphic design background, not coding ;)

Are there any sites/tuts on "Intro to Linux programming" that you'd recommend. Im sure I'l find a a large amount of them when I google but any in particular you enjoy?

thanks again.

mandeltuete 05-13-2005 01:50 PM

uh, I can't give you any url or so, but C is quite similar to php. for example 'if', 'while', etc. are used exactly the same way. the only big difference are the variables, which you have to declare first. strings are also more difficult in C than in php.

I heard "Learning C in 21 days' would be a good start.. anyway I would suggest you using google and looking for a tutorial which seems understandable for you. or just search in this forum, maybe someone else has asked for c tuts before.

make sure that you know functions, pointers and strings before you dive into gtk.. I also would suggest you keeping it simple, so you don't have to know what structs are and so on, just what you need for gtk..

A lot of fun with it!


All times are GMT -5. The time now is 08:37 PM.