3 ms·
> However, win32 doesn’t have anything to help you layout things on the screen. Manual positioning is painful. Ooooh, yes, I remember that. My first experience
by krylon 9y ago
> However, win32 doesn’t have anything to help you layout things on the screen. Manual positioning is painful.
Ooooh, yes, I remember that. My first experiences with GUI programming was a tiny little of Perl/Tk, then Gtk 2 in Perl, Python, and Ruby.
And then I started working as programmer, doing maintenance on an line-of-business application suite written in C/Win32, and I was shocked people would actually put up with this. Fortunately, the overwhelming majority of my work dealt with the deepest guts of those programs, and I only needed to deal with Win32 directly on a few occasions.
- sjmulder 9y agoI've started writing some Win32 code for fun and like you I found it a whole different experience from GTK and such. It really is an API rather than a toolkit. Take scrolling. Scroll bars are provided when requested, but all the interactions have to be implement by the application. There's no 'scroll view' with standard behaviours. This means Microsoft can't easily add new scrolling behaviours as we see with the messy situation around high precision trackpads and touch. Compare this to Cocoa with its auto layout, data binding and even document lifecycle management. On the other hand, with Win32 I rarely find myself fighting the toolkit. I'm in control. Backwards comatibility is also amazing. With my little project I'm targeting Windows 3.1 through Windows 10 with a single binary! I expected most of my effort to go towards supporting old OSes, but in reality I spend more time on modern features like proper per-monitor DPI suport, the gazillion different scrolling behaviours and (conditionally loaded) GDI+ and Direct2D implementations. Another delightful aspect, although again it comes the beforementioned price, is the speed. My little utility starts instantly and won't skip a beat when you frantically shake the resize grip. Compare that to even the simplest UWP XAML app.
- krylon 9y ago> Another delightful aspect, although again it comes the beforementioned price, is the speed. That is true, with only a little care, one can write insanely fast and responsive UIs in Win32.
- aninteger 9y agoIt's funny you mention that. I grew up with the Windows API first and then moved to Tcl/To, and then Swing. I remember wishing I could just manually position things instead of packing into horizontal and vertical boxes. Maybe it is Stockholm syndrome with the Windows API for me.
- krylon 9y agoIn my experience, generally, when I have work with some piece of technology that works differently from what I am used to, it is highly frustrating. All the habits that normally would make things easier for me suddenly are working against me.
- pjmlp 9y agoWhich is why already on the Win16 days only masochists would program in straight Win16, let alone when Win32 arrived. The sane of us were already using OWL (TP, C++), MFC(C++), VB, VCL (C++, Delphi), Visual Fox Pro (xBase). And the reason why on Windows world C was mostly relevant for kernel and drivers programming, with other languages taking over actual application development.
- krylon 9y ago> only masochists would program in straight Win16, let alone when Win32 arrived Also, electrical engineers. ;-) At least I learned a lot about C. And I learned that friendly coworkers make up for a lot of stuff that would drive me insane otherwise.