Thread: thinking about learning gui stuff

  1. #1
    Registered User
    Join Date
    Apr 2019
    Posts
    662

    thinking about learning gui stuff

    any advice for learning c gui stuff or if it can even be done with c

  2. #2
    Registered User
    Join Date
    Feb 2019
    Posts
    555
    Quote Originally Posted by cooper1200 View Post
    any advice for learning c gui stuff or if it can even be done with c
    For Windows: Charles Petzold - Programming Windows 5th ed
    For Linux (or any other platform if you want portability): GTK+

  3. #3
    Registered User
    Join Date
    May 2019
    Posts
    213
    Notice the "for Windows" and "for others" pattern here.

    In C, you're tied to a platform. In the 21st century that really doesn't fit.

    The Petzold book is classic....as in applicable to Windows 3.1 from the 80's, updated for the 90's and the recent Windows releases. It is the gold standard for books on the subject of Windows GUI programming at the API's native level (C).

    Just skim it's 1000 pages. You'll need about 600 of them to make any Windows application function.

    There's a different text or texts of similar density awaiting you for Linux (GNome/KDE/whatever), and then, if you don't want to exclude MAC, yet another for the Objective-C language on the OS-X GUI, unless you prefer Swift.

    Now, it can be done in C. It was done in C for many years.

    Anyone who knows C++ would never again make a GUI application in C. For that matter, many who know C# won't bother with C/C++ at all if their application is of simple or moderate ambition.

  4. #4
    Registered User
    Join Date
    Apr 2019
    Posts
    662
    im just thinking about the next thing to learn. i don't want to get too deep into c as my overall goal is to do some stuff with the arduino

  5. #5
    Registered User
    Join Date
    May 2019
    Posts
    213
    Then GUI in C is definitely not on your current list. You'd have to get through about page 350 in Petzold just to make simple things work.

    Now, if you grab a copy of WxWidgets you'd have a few day's study on a GUI app, with something working. They have samples which give good starting points. Of course, it's not C..C++.

  6. #6
    Registered User
    Join Date
    Apr 2019
    Posts
    662
    what would you recommend i learn next then while i wait for my arduino to arrive

  7. #7
    Registered User
    Join Date
    May 2019
    Posts
    213
    My own personal prejudices naturally provoke me to suggest an intro to C++ if it's not familiar.

    However, you may enjoy certain specific projects more pertinent to the Arduino, and that depends on what features your board will have. Some communicate through RS-232 (an old serial interface most PC's don't even have these days), while some through USB and others over WiFi or Bluetooth. Each of these have their own programming techniques for connection a standard C/C++ application running on Linux/Window/MAC to the Arduino. The result is a way to interface an Arduino, with code you write for the Arduino with it's software tools, and a PC application.

    While I can't recommend this for C, if in C++ you might enjoy a quick tour of a simple AI exercise, training a net to recognize hand written digits 0 to 9.
    Last edited by Niccolo; 06-16-2019 at 03:37 PM.

  8. #8
    Registered User catacombs's Avatar
    Join Date
    May 2019
    Location
    /home/
    Posts
    72

    An Introduction to C and GUI Programming
    might be what you're looking for.

  9. #9
    Registered User
    Join Date
    Apr 2019
    Posts
    662
    @niccolo its going to have a usb interface as as you said i dont have a serial (rs-232) the ai thing sounds interesting any links?

  10. #10
    Registered User
    Join Date
    May 2019
    Posts
    213
    The first and second links may be best (second is a kind of journal for someone exactly where you are, trying this out).

    One link is a database of handwritten scanned data.

    Others, toward the bottom, may be more technical and ambitious.

    It IS easier in C++, but....you could manage this in C.

    How long for the Arduino to arrive?



    Neural networks and deep learning

    My first steps in deep learning — recognising handwritten digits


    IAM Handwriting Database — Computer Vision and Artificial Intelligence

    Applying Machine Learning to Recognize Handwritten Characters

    How To Build a Neural Network to Recognize Handwritten Digits with TensorFlow | DigitalOcean

  11. #11
    TEIAM - problem solved
    Join Date
    Apr 2012
    Location
    Melbourne Australia
    Posts
    1,859
    I really enjoyed learning about encryption, but I'd suggest that you actually buy an Arduino and start trying different things.

    Start with a blinking LED, UART comms,...

  12. #12
    TEIAM - problem solved
    Join Date
    Apr 2012
    Location
    Melbourne Australia
    Posts
    1,859
    I think that I said to you the other week that I once learned how to write a GUI with C - It was interesting, but not very useful...

    My advice was to learn C# or Python to get started with GUI programming

    /Edit
    Do you have a target that you want to write a GUI on? Mint?
    Last edited by Click_here; 06-16-2019 at 06:30 PM.

  13. #13
    Registered User
    Join Date
    Apr 2019
    Posts
    662
    @ niccolo thanks for the info the arduino should be here by the end of the week.

    @ click here it would be for mint but i was thinking of eventually writting a gui for my arduino projects but by all the advice i have received and what i have found online its going to be hard going doing it in c for little gain

  14. #14
    TEIAM - problem solved
    Join Date
    Apr 2012
    Location
    Melbourne Australia
    Posts
    1,859
    What do you mean by "GUI for my Arduino projects"?

  15. #15
    Registered User
    Join Date
    Apr 2019
    Posts
    662
    well one of the things i was thinking of doing was having an arduino control various things to be set over the wifi so i could tell the arduino turn my light on away from home. a simple gui for that might be usefull

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Thinking of learning assembler, ARM?
    By Subsonics in forum Tech Board
    Replies: 8
    Last Post: 06-15-2009, 04:30 PM
  2. Thinking about learning something else
    By tiachopvutru in forum A Brief History of Cprogramming.com
    Replies: 31
    Last Post: 06-24-2008, 02:45 PM
  3. Hangman, Help me with the thinking
    By Livijn in forum C# Programming
    Replies: 14
    Last Post: 02-09-2008, 03:16 PM
  4. too much thinking?
    By willc0de4food in forum Windows Programming
    Replies: 9
    Last Post: 10-03-2006, 05:34 AM
  5. I know you've been thinking about this...
    By Aran in forum A Brief History of Cprogramming.com
    Replies: 43
    Last Post: 11-08-2001, 04:13 PM

Tags for this Thread