Тёмный

Creating a GObject in C 

Christian Hergert
Подписаться 559
Просмотров 15 тыс.
50% 1

A tutorial on how to create a GObject in C

Опубликовано:

 

15 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 45   
@Guilherme-ps6sp
@Guilherme-ps6sp 5 месяцев назад
Thank you for this very useful video!
@jimmacfx
@jimmacfx 8 лет назад
Really well put together! Nice hat, also.
@umangjain2
@umangjain2 8 лет назад
Really great tutorial. I was just a beginner and now I have submitted 4-5 patches in just one week because I have watched this video. I got more insight in GObject's working therefore was able submit patches. Will see you at IRC :)
@gzy3867
@gzy3867 3 года назад
Christian, This tutorial is absolutely amazing. You know your stuff and are in one of the very small percent of really good teachers out there. I have looked at your other uploads which I also find very interesting! It's also great to see who is making the IDE I use :) If you can and want to spend time making GObject tutorials this would be greatly appreciated by me and as it looks by many other people!
@JohnnyRicha
@JohnnyRicha 4 года назад
This is so amazing content, please do more. I'm waiting for more of your gobject videos for a while.
@tainakarinelimacostadaroch4353
@tainakarinelimacostadaroch4353 6 месяцев назад
Please, could you create another tutorial on how to use GObject in a more up-to-date way because your last video is 8 years old and I'm having a lot of difficulty getting started with classes, how to let them inherit or don't understand in your video you don't use G_TYPE_CHECK_INSTANCE G_TYPE_CHECK_CLASS, I would like I really understand why it became mandatory to put person_set_property since it was built automatically, I really wanted a video, I can't study the documentation, please I need your help, I really want to understand, thank you very much in advance
@abulkasimlaskar
@abulkasimlaskar 7 лет назад
Nice tutorial. Looking forward for more such tutorial . Its very difficult for newbies to understand GObject and related contents concept and there were very few tutorial for there help. Thanks a lot ...
@adrienplazas554
@adrienplazas554 8 лет назад
Nice tutorial! It's really a good idea to have them as videos and the result is well structured and pleasing to watch. Great job. =)
@tainakarinelimacostadaroch4353
@tainakarinelimacostadaroch4353 6 месяцев назад
Could you make a basic tutorial on how to use GObject showing it extending from another class using super() and showing how to use the types of the class created using macros
@maartenduijndam6660
@maartenduijndam6660 5 лет назад
Hi Cristian! Thanks for your introduction for writing GObjects, great and relaxed introduction! One note I think you mean to write g_strcmp0(name, self->name) != 0 in the function example_person_set_name. Because otherwise you'll only set the name when they are equal, while you intend to reset the name when they aren't equal.
@IsaqueGaldino
@IsaqueGaldino 8 лет назад
This is a really nice tutorial. Thank you!
@igormorgado
@igormorgado 4 года назад
Hello Christian, amazing Video, where can I find the next part?
@johanouwerkerk6642
@johanouwerkerk6642 8 лет назад
Could the PROP_NAME have been declared as PROP_NAME=1 in the enum to automatically offset the enum values by one or would that break something? (Also any reason why the offset is apparently not necessary for the signal?) Finally a little bug: your name setter only does something if the names are ... in fact, equal (== 0).
@vwduder
@vwduder 8 лет назад
+Johan Ouwerkerk You could very well do PROP_MY_FIRST_PARAM = 1. But we tend to just do PROP_0 everywhere as convention. The offset isn't required for signals because they don't have the requirement that id's be non-zero (like properties do). Historical issue, of course. Thanks for catching the setter issue, I didn't catch it until after production :(
@1998goodboy
@1998goodboy 7 лет назад
Hi, I'm wondering, apart from googling (and youtubing) how can I get started on programming in c/c++ and gtk?? Is there an IRC channel? Or can I maybe contact you directly? I already know a bit more than the basics of programming and familiar with OOP concepts. I really just want to develop me programming knowledge, and want to start contributing back to the opensource community.
@vwduder
@vwduder 7 лет назад
Join #newcomers irc channel on irc.gnome.org. There are a bunch of us that can help direct you towards projects to help build your skillset.
@1998goodboy
@1998goodboy 7 лет назад
Thanks a lot Chris, just one more question, where are most of the people on that channel from? Just want to know so I can better sync up with the timezone.
@vwduder
@vwduder 7 лет назад
1998goodboy pretty much around the globe, though mostly Europe and US. although it's the weekend now...
@1998goodboy
@1998goodboy 7 лет назад
Thanks a lot for your help! ill surely be in there!
@techinternals
@techinternals 4 года назад
This is video is lovely, I am gonna subscribe this channel
@tobias47n9e
@tobias47n9e 8 лет назад
Really cool and easy to follow!
@Rihisogre
@Rihisogre 5 лет назад
Hey! Thanks for the lesson! Learned a lot. I have one question. How can i use these GObjects between multiple files for example - What are methods to access ExamplePerson *self from another source file? Waiting for follow up video! Cant find a lot of info and examples on this, so another video with GTK composite widget templates would be very useful.
@baruchben-david4196
@baruchben-david4196 6 лет назад
Love the shapka.
@baskaisimkalmamisti
@baskaisimkalmamisti 4 года назад
I have learned a lot! thanks
@jambexuk
@jambexuk 5 лет назад
Why do you leave a space between the function name and curved brackets? --> helloWorld () instead of helloWorld()
@BlazertronGames
@BlazertronGames 5 лет назад
It's just a style choice, there's no difference. Remember, C doesn't care about white space in most cases.
@sasaostrouska888
@sasaostrouska888 8 лет назад
Thanks for that nice video. It is sad that Gnome have not a good book about that stuff or even written on some wiki, probably somebody would need to step up to do that. Make it simple for us newbies also. Those videos could be a nice step forward for the gnome-university :) And as last, please try to explain things slowly as sometimes we not natively english speakers do not catch every phrase clearly. Thanks again and very well done Christian !!!!
@vwduder
@vwduder 8 лет назад
+Sasa Ostrouska Thanks I'll take the suggestions to heart! Also, there is this tutorial, but I think we could do some cool things with video + chapter material. developer.gnome.org/SubclassGObject/
@sasaostrouska888
@sasaostrouska888 8 лет назад
+Christian Hergert , many thanks ! I think I have ot strugle a bit more on the gnome.org wiki :) But yeah count on me if I can help to put together something better :)
@g9in
@g9in 8 лет назад
What's the name of the tool that you used in this video?
@vwduder
@vwduder 8 лет назад
GNOME Builder (an IDE that I'm writing with some other folks)
@g9in
@g9in 8 лет назад
Thank you. One more, What's the OS you use?
@vwduder
@vwduder 8 лет назад
+박종영 Fedora 25 beta right now
@karan26mumbai
@karan26mumbai 7 лет назад
hey Christian, Which laptop do you use for development? I am looking to buy one.
@naheelazawy
@naheelazawy 7 лет назад
Still waiting for you next video
@sooqua
@sooqua 5 лет назад
Wtf is that autocompletion dark magic???
@nathanielmccallum2827
@nathanielmccallum2827 8 лет назад
Don't use guards! Use #pragma once.
@vwduder
@vwduder 8 лет назад
I'll probably change it in the future, but note pragma once is *not* faster on gcc.
@nathanielmccallum2827
@nathanielmccallum2827 8 лет назад
+Christian Hergert I don't care about faster. I care about error prone (such as name collisions).
@MathieuDuponchelle
@MathieuDuponchelle 8 лет назад
+Nathaniel McCallum pragma once isn't standard though ;)
@nathanielmccallum2827
@nathanielmccallum2827 8 лет назад
+Mathieu Duponchelle it isn't standard, but it is supported by all major compilers.
@MathieuDuponchelle
@MathieuDuponchelle 8 лет назад
Sure, but using it or not depends on whether you care more about code conciseness or about portability, can't just say "Use #pragma once" :)
Далее
Learning Gnome Development in C
1:10:32
Просмотров 5 тыс.
@HolyBaam ультанул в конце 🧨
00:34
Просмотров 192 тыс.
Каха и жена (недопонимание)
00:37
Let's Create a Compiler (Pt.1)
1:11:03
Просмотров 516 тыс.
MIT is first to solve problem C
0:28
Просмотров 3,2 млн
Why I’m Switching To Go in 2024
8:10
Просмотров 57 тыс.
I Hacked Diablo II To Use Modern Graphics
13:16
Просмотров 94 тыс.
The hidden beauty of the A* algorithm
19:22
Просмотров 862 тыс.
Dive into GObject | Part 1
3:34:14
Просмотров 2,5 тыс.
Bit Fields in C. What are they, and how do I use them?
13:26
Port your widgets to GTK 4 - Matthias Clasen
50:03
Просмотров 8 тыс.
@HolyBaam ультанул в конце 🧨
00:34
Просмотров 192 тыс.