Re: Skia library for D, porting from SkiaSharp API.

2021-12-07 Thread Imperatorn via Digitalmars-d-announce

On Monday, 6 December 2021 at 09:08:20 UTC, zoujiaqing wrote:
SkiaD is a cross-platform 2D graphics API for D based on Mono's 
SkiaSharp. It provides a comprehensive 2D API that can be used 
across mobile, server and desktop models to render images.


https://github.com/gearui/skiad


Nice, consider adding it to dub if you haven't done so already 


Re: DQt: Qt bindings using extern(C++)

2021-12-07 Thread Tim via Digitalmars-d-announce

On Tuesday, 7 December 2021 at 06:33:18 UTC, MGW wrote:
Can you explain in more detail some points that are difficult 
for me:


widgets/label.d file. I see a C++ mapping of class 
QLabelPrivate to structure D

extern(C++, class) struct QLabelPrivate;
this makes sense.

I see below an implementation of a class D named QLabel
class /+ Q_WIDGETS_EXPORT +/ QLabel : QFrame
in which I see calls to methods of the QLabel class.

I don't understand at what stage (where exactly) the mapping
QLabelPrivate structure methods onto QLabel methods.

I expected to see something like:
QLabelPrivate dd = QLabelPrivate(...);
and then
dd.MetodsQLabel(...)

Can you explain this place in more detail.


QLabel is also extern(C++), because the top of the file has 
"extern(C++):". Most methods in QLabel are directly implemented 
in the Qt library. Some are also implemented in D. For example 
QLabel.setText has a wrapper accepting the text without ref, so 
it can be called without creating a temporary variable.


QLabelPrivate is used internally by Qt. This declaration is 
actually unused in the bindings. Many Qt types have a pointer to 
private data. New versions of Qt can then change the private data 
without changing the ABI between Qt libraries and applications. 
The constructor of QLabel creates an instance of QLabelPrivate 
and passes it to the constructor of the parent class 
(https://code.woboq.org/qt5/qtbase/src/widgets/widgets/qlabel.cpp.html#213). QObject stores it then as d_ptr.


Re: DConf Online 2021 Q & A Videos

2021-12-07 Thread jmh530 via Digitalmars-d-announce

On Sunday, 5 December 2021 at 11:01:05 UTC, Mike Parker wrote:

[snip]

I'll likely be working on this for the remainder of this month. 
I'll try to get them out every three or four days, and I'll 
continue to update this thread with the new links.


Stefan's Q & A session is next.


Thanks for putting in the effort. Better to watch the edited ones.