www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Another Tuesday (Friday?), Another GtkDcoding Blog Post

reply Ron Tarrant <rontarrant gmail.com> writes:
It was suggested that I do all these posts in one thread, so this 
is the thread where that'll happen. With that said...

It's Tuesday! (and that used to be a Theatresports game when 
Keith Johnstone still ran things)

OR...

It's Friday!

And that (the Tuesday OR Friday part) means it's time for another 
post on the gtkDcoding blog. Here it is: 
http://gtkdcoding.com/2019/03/12/0017-change-pointer.html

Today's topic: Changing the mouse pointer

You'll be thrilled by the heart-shaped point and tickled by the 
Gumby. Man, this stuff is exciting!

Sign up for RSS or follow on Facebook or drop me some email.

Anyway. 'Nuff said.
Mar 12 2019
next sibling parent reply jmh530 <john.michael.hall gmail.com> writes:
On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 It was suggested that I do all these posts in one thread, so 
 this is the thread where that'll happen. With that said...

 [snip]
I thought the suggestion was one thread in the Announce forum, rather than multiple threads in the Announce forum...rather than one thread in the Learn forum.
Mar 12 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Tuesday, 12 March 2019 at 15:15:00 UTC, jmh530 wrote:
 I thought the suggestion was one thread in the Announce forum, 
 rather than multiple threads in the Announce forum...rather 
 than one thread in the Learn forum.
It's a learning resource, so wouldn't that go here? Or am I misinterpreting the intention of the Learn sub-forum? If you a moderator believes it should move, please feel free.
Mar 12 2019
parent reply jmh530 <john.michael.hall gmail.com> writes:
On Tuesday, 12 March 2019 at 15:35:03 UTC, Ron Tarrant wrote:
 [snip]

 It's a learning resource, so wouldn't that go here? Or am I 
 misinterpreting the intention of the Learn sub-forum?

 If you a moderator believes it should move, please feel free.
It's a learning resource, sure, but you're also announcing a new blog post. Tricky.
Mar 12 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Tuesday, 12 March 2019 at 16:08:46 UTC, jmh530 wrote:
 Tricky.
My thinking exactly. (I would have replied with a simple, "Yup," but I did that once before and the forum software made me do a Capcha.)
Mar 12 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
It's Friday and time for another post on the GtkDcoding blog. 
This time around, it's about text Entry widgets, both editable 
and non-editable.
Mar 15 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Friday, 15 March 2019 at 09:21:28 UTC, Ron Tarrant wrote:
 It's Friday and time for another post on the GtkDcoding blog. 
 This time around, it's about text Entry widgets, both editable 
 and non-editable.
Oops! Here's the link: http://gtkdcoding.com/2019/03/15/0018-variations-on-a-text-entry.html
Mar 15 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
Tuesday again. This blog post is about invisible Entry widgets 
and the FontButton. Really stimulating stuff and you'll find it 
at: 
http://gtkdcoding.com/2019/03/19/0019-disappearing-text-entry.html
Mar 19 2019
parent reply number <putimalitze gmx.de> writes:
On Tuesday, 19 March 2019 at 12:33:08 UTC, Ron Tarrant wrote:
 Tuesday again. This blog post is about invisible Entry widgets 
 and the FontButton. Really stimulating stuff and you'll find it 
 at: 
 http://gtkdcoding.com/2019/03/19/0019-disappearing-text-entry.html
A little copy/paste glitch.. code (on blog and on github) says 'text entry box' where a FontButton is used:
 writeln("The text entry box holds: ", fontButton.getFontName());
Mar 22 2019
parent Ron Tarrant <rontarrant gmail.com> writes:
On Friday, 22 March 2019 at 16:40:31 UTC, number wrote:

 writeln("The text entry box holds: ", 
 fontButton.getFontName());
Again, thank you for catching typos.
Mar 22 2019
prev sibling next sibling parent reply number <putimalitze gmx.de> writes:
On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 another post on the gtkDcoding blog.
0010 says
 Here’s the code file.
 Here’s a second code file for you.
but no links. I guess it's https://github.com/rontarrant/gtkDcoding/blob/master/003_box/box_003_03_checkbutton.d and https://github.com/rontarrant/gtkDcoding/blob/master/003_box/box_003_04_togglebutton.d
Mar 21 2019
next sibling parent reply number <putimalitze gmx.de> writes:
On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 another post on the gtkDcoding blog.
0013 says
 ... with *setTooltipText()*.
Maybe a formatting error? Thanks again for the Blog. FYI: I also had dropped a note in some of the previous gtkdcoding forum threads
Mar 22 2019
parent Ron Tarrant <rontarrant gmail.com> writes:
On Friday, 22 March 2019 at 10:02:24 UTC, number wrote:
 On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 another post on the gtkDcoding blog.
0013 says
 ... with *setTooltipText()*.
Maybe a formatting error?
Yup, it was. I'm still trying to break the habit of putting optional stuff in angle brackets, '<' and '>,' which markdown doesn't like. Thanks for catching that.
 Thanks again for the Blog.
I'm delighted anybody's reading it. :)
 FYI: I also had dropped a note in some of the previous 
 gtkdcoding forum threads
I'll have a look. Sorry I missed your remarks.
Mar 22 2019
prev sibling parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Thursday, 21 March 2019 at 20:49:07 UTC, number wrote:
 On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 another post on the gtkDcoding blog.
0010 says
 Here’s the code file.
 Here’s a second code file for you.
but no links. I guess it's https://github.com/rontarrant/gtkDcoding/blob/master/003_box/box_003_03_checkbutton.d and https://github.com/rontarrant/gtkDcoding/blob/master/003_box/box_003_04_togglebutton.d
Hmm... I'm not sure why the links didn't show up for you. I just double-checked and they're in the .md file and version of the file has been in place for at least 10 days. Still, no harm in having them on this forum as well. Thanks for taking an interest.
Mar 22 2019
parent reply number <putimalitze gmx.de> writes:
On Friday, 22 March 2019 at 11:19:56 UTC, Ron Tarrant wrote:
 Hmm... I'm not sure why the links didn't show up for you. I 
 just double-checked and they're in the .md file and version of 
 the file has been in place for at least 10 days.

 Still, no harm in having them on this forum as well.

 Thanks for taking an interest.
Not sure about .md or file version, but there are no links in the actual blog post: http://gtkdcoding.com/2019/02/15/0010-checkbutton.html and apparently also not in in this .md file: https://raw.githubusercontent.com/rontarrant/gtkDcoding/master/docs/_posts/2019-02-15-0010-checkbutton.md
Mar 22 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Friday, 22 March 2019 at 13:17:23 UTC, number wrote:

 Not sure about .md or file version, but there are no links in 
 the actual blog post:
 http://gtkdcoding.com/2019/02/15/0010-checkbutton.html
It's fixed now.
 and apparently also not in in this .md file:
 https://raw.githubusercontent.com/rontarrant/gtkDcoding/master/docs/_posts/2019-02-15-0010-checkbutton.md
This is actually the .md source file for the above html file, so it's fixed, too. Thanks for catching yet another broken link.
Mar 22 2019
parent reply number <putimalitze gmx.de> writes:
On Friday, 22 March 2019 at 23:34:08 UTC, Ron Tarrant wrote:
 It's fixed now.
The first one :), now there's still the other one "Here’s a second code file for you."
Mar 23 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Saturday, 23 March 2019 at 07:18:02 UTC, number wrote:
 The first one :), now there's still the other one "Here’s a 
 second code file for you."
Done. Thanks, eh.
Mar 24 2019
parent reply Ron Tarrant <rontarrant gmail.com> writes:
Sunday Blog eXtra: Installing and Using a Linux Build Environment

URL: 
http://gtkdcoding.com/2019/03/24/x0002-gtkd-in-a-linux-environment.html
Mar 24 2019
next sibling parent Ron Tarrant <rontarrant gmail.com> writes:
Tuesday, March 26, 2019

And today's blog post covers creating a Label with a non-default 
background colour.

You can find it here: 
http://gtkdcoding.com/2019/03/26/0021-labels-with-background-colors-markup.html
Mar 26 2019
prev sibling parent number <putimalitze gmx.de> writes:
On Sunday, 24 March 2019 at 19:20:47 UTC, Ron Tarrant wrote:
 Sunday Blog eXtra: Installing and Using a Linux Build 
 Environment

 URL: 
 http://gtkdcoding.com/2019/03/24/x0002-gtkd-in-a-linux-environment.html
Thanks for the new posts. Link dead? It's also not listed on the blog post list. But I have read it some days before, and what I noticed is that you used the sources from ~/.dub/packages/gtk-d-... I suspect you played with dub + gtkd by that time because I think they wouldn't be there otherwise. So if you use dmd in the example you might want to better use /usr/include/dmd/gtkd3/ (after installing gtkd). I installed gtkd recently like shown here https://github.com/gtkd-developers/GtkD/wiki and here https://d-apt.sourceforge.io/ which was basically this (-85 being my dmd version): sudo wget https://netcologne.dl.sourceforge.net/project/d-apt/files/d-apt.list -O /etc/apt/sources.list.d/d-apt.list sudo apt-get update --allow-insecure-repositories && sudo apt-get -y --allow-unauthenticated install --reinstall d-apt-keyring && sudo apt-get update sudo apt install libgtkd3-85 libgtkd3-dev libgtkd3-doc and I compile like this: dmd -de -w -m64 -I/usr/include/dmd/gtkd3/ -L-lgtkd-3 -run label_008_02_markup.d Not sure if you need the -m64 on x64 linux with a dmd64, should be the default then and works without.
Mar 26 2019
prev sibling next sibling parent reply Michelle Long <HappyDance321 gmail.com> writes:
On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 It was suggested that I do all these posts in one thread, so 
 this is the thread where that'll happen. With that said...

 It's Tuesday! (and that used to be a Theatresports game when 
 Keith Johnstone still ran things)

 OR...

 It's Friday!

 And that (the Tuesday OR Friday part) means it's time for 
 another post on the gtkDcoding blog. Here it is: 
 http://gtkdcoding.com/2019/03/12/0017-change-pointer.html

 Today's topic: Changing the mouse pointer

 You'll be thrilled by the heart-shaped point and tickled by the 
 Gumby. Man, this stuff is exciting!

 Sign up for RSS or follow on Facebook or drop me some email.

 Anyway. 'Nuff said.
I'd suggest adding pictures! It's very easy to take a screen shot and not much harder to link them and they offer far more interest.
Mar 21 2019
next sibling parent Ron Tarrant <rontarrant gmail.com> writes:
On Thursday, 21 March 2019 at 21:34:26 UTC, Michelle Long wrote:

 I'd suggest adding pictures! It's very easy to take a screen 
 shot and not much harder to link them and they offer far more 
 interest.
You're the second person to suggest this, so I'll explain my reasoning. I assure you, it's not because I'm lazy or don't know where the Print Screen button is. :) My original plan was to include screenshots. Then I thought back over my own experiences with reading tutorial sites. I have a tendency to look at the screenshot, skim the article, copy-n-paste the code, and go off to do other things. I've also noticed this in others. It's often quite obvious someone hasn't read something carefully just by the questions they ask (present company excluded). And I think images deter people from paying close attention while reading. I can't back this up with statistics or research other than my own, but I have noticed a decline in reading comprehension over the last 30 years as the Internet went from text-only to images and ads filling our screens. So the bottom line is, by leaving out images, I feel I'm doing my bit for literacy. If there's nothing else besides text, it's all the reader has to engage with and I'm hoping this will engender a complete understanding of the subjects I cover... as much as is possible. It's also why I keep the frills down to an absolute minimum. I've tossed thousands of words because they veered too far off topic or were written just to get a laugh or whatever. And there you have it, the philosophy behind gtkDcoding. Thanks for reading, Michelle. And keep the comments coming, please.
Mar 22 2019
prev sibling parent reply Ron Tarrant <rontarrant gmail.com> writes:
On Thursday, 21 March 2019 at 21:34:26 UTC, Michelle Long wrote:

 I'd suggest adding pictures!
Oops! Forgot to say... I get why you want images. You were asking about animation the other day, so obviously you're a visual artist. So am I and I know how drawn I am to imagery and I imagine most artists are. Again, thanks for your feedback, Michelle.
Mar 22 2019
parent Ron Tarrant <rontarrant gmail.com> writes:
Also forgot...

It's Friday again and time for another gtkDcoding blog post. In 
today's episode, we slap an image onto a Timmy the Button's face, 
then do a switch up to keep poor Timmy off balance. You can tune 
in here:

http://gtkdcoding.com/2019/03/22/0020-image-buttons.html
Mar 22 2019
prev sibling parent reply number <putimalitze gmx.de> writes:
On Tuesday, 12 March 2019 at 14:44:59 UTC, Ron Tarrant wrote:
 
As a side note, in 0004 you say:
 We can still call the constructor, even though strictly 
 speaking it’s private, because by using ‘new MyButton()’ the 
 constructor isn’t being called directly, but as part of a 
 lower-level process for instantiating the object.
I'm still new to D too, but I think it works in this scenario because private in D works on the module/file level. main/TestRigWindow/MyButton are defined in the same file (module) and thus can access each others private members. If you put the button class in its own file/module and import it then you would have to make its constructor public to access it.
 button_002_04_oop_arg.d(22): Error: class 
 `button_002_04_oop_arg_2.MyButton` member this is not accessible
Mar 22 2019
parent Ron Tarrant <rontarrant gmail.com> writes:
On Friday, 22 March 2019 at 13:58:48 UTC, number wrote:

 I think it works in this scenario because private in D works on 
 the module/file level.
By gar, you're right. I hadn't even looked into this because I assumed it was the same as PHP and C++. Thanks for pointing this out.
Mar 22 2019