On Fri, 06 Mar 2015 08:09:15 +0000, Kagamin wrote: > On Thursday, 5 March 2015 at 15:01:20 UTC, ketmar wrote: >> oh, really? so no deep widget ierarchies, no way to position the widget >> (as we doesn't store it's coordinates), no way to... no way to define >> anything. that's will be great GUI! > > To position a widget you invoke a backend function on a widget handle > with desired coordinates.
smells like windows. >> by the way. what is "backend widget handle" for OpenGL, for example? >> ah, >> i see, your idea of "backend" is that backend implements the whole >> widget system. > > Yes, the point is to make frontend agnostic about backend implementation > details. If you want to write entire widget system from scratch, like > FLTK, that goes to a backend. so you proposing to throw frontend away, as the only thing that "frontend" keeps is a some handle, that's all. and what the sense of such "frontend"? besides, your arch is not portable at all. i.e. to port it to another graphic system author has to rewrite the whole thing (as 99% of code is in "backend", and have to be rewritten). so it's easier to drop all that mess and just write direct X11 calls. that's exactly what you are proposing: a single "backend" handle and alot of "frontend" functions that manipulates that handle.
signature.asc
Description: PGP signature