Simplifying code

Discussion of chess software programming and technical issues.

Moderators: Harvey Williamson, Dann Corbit, hgm

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
User avatar
mvanthoor
Posts: 560
Joined: Wed Jul 03, 2019 2:42 pm
Full name: Marcel Vanthoor

Re: Simplifying code

Post by mvanthoor » Sun Nov 08, 2020 3:56 pm

hgm wrote:
Sun Nov 08, 2020 8:50 am
Well, be forewarned that writing a GUI is typically about 100 times as much work as writing an engine.
I know. And I'm not even a GUi programmer to be honest; I don't really like writing GUI's.

On the other hand, I like most of the current GUI's even less; each for their own reasons. I still like the old Fritz 11 GUI the best.
I am not sure what exactly you mean by 'high-resolution display'. WinBoard has always supported square sizes up to 129x129 pixels to cater to the higher resolutions, and allowing even larger square sizes would be a trivial modification. XBoard now uses SVG images for the pieces, which can be scaled to arbitrary size without loss of quality.
I just don't like Winboard as a GUI. I've been using Fritz-type GUI's since the 2000's; Winboard feels alien to me. I'm also of the opinion that it is much more complex than I need. As I said earlier... I like the Fritz 11 GUI the most. It's just a no-nonsense chess GUI that happens to be able to do what I need, and nothing more. Same is true for the Shredder GUI (which is basically in the same style). Arena is in the same style as well, but much less intuitive and with a lot of (sometimes conflicting...) settings.

Obviously I will install Winboard to test the CECP-protocol when I test it in my engine, but I doubt that it will become my main GUI.

With regard to high-dpi monitors, you're right: many GUI's use fixed-size controls and bitmapped imagse. They don't take well to being scaled or having font sizes set that are larger than the defaults. They either get blurry, or fall apart completely.

User avatar
mvanthoor
Posts: 560
Joined: Wed Jul 03, 2019 2:42 pm
Full name: Marcel Vanthoor

Re: Simplifying code

Post by mvanthoor » Sun Nov 08, 2020 4:02 pm

Henk wrote:
Sun Nov 08, 2020 9:38 am
Might be WinBoard/XBoard does not exist in the future like CTF. Same may hold for Arena.
I even remember that I accidentally deleted or moved Winboard on my computer.
There will always be some other chess gui; but you are right with that one. I've been looking for engines in the 1450-1950 CCRL Elo range to test against, but many I try to download are just gone. The website doesn't exist anymore, and most have been gone so long that the WayBack machine doesn't have it on archive. The rating lists holds many engines that have been written, thrown onto github, tested one version or another, and then abandoned. Many have bugs in their output (and some don't even have any info output at all), which would make them completely useless as an analysis engine.

The same is true for many GUI's. There are lots of them, but often they're just abandoned, or development stalls for many years. Same happened to Picochess. Development was essentially halted in 2018. (That is the reason why I intend to lift the DGT E-board communication from it and start rewriting a version in Rust, some day. I intend to try and upgrade the libraries of the current version, so other people could develop this version further, but I probably won't be developing on top of it. I don't want to get into python for my personal projects.)

User avatar
hgm
Posts: 25424
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: Simplifying code

Post by hgm » Sun Nov 08, 2020 4:38 pm

mvanthoor wrote:
Sun Nov 08, 2020 3:56 pm
With regard to high-dpi monitors, you're right: many GUI's use fixed-size controls and bitmapped imagse. They don't take well to being scaled or having font sizes set that are larger than the defaults. They either get blurry, or fall apart completely.
I just wanted to point out that the XBoard GTK build is very nice in this respect. Both fonts and pieces are scalable without loss of image quality. The dialogs and controls these contain just use the default system theme, which can be expected to be set correctly for the resolution you have. WinBoard is not so nice; it needs a separate set of fixed-sized bitmaps for each square size. But it also has font-based piece rendering, and this works well at the larger square sizes. (At smaller square sizes the outlines of most chess fonts get 'leaky', and the flood-fill algorithms fail.)

I don't know Fritz, really. I always thought that WinBoard was ultimately simple, for doing simple things: you just see a chess board and clocks, and can start playing immediately, or set the engine to move through a menu item.
Get rid of the shit: vote for SHID!

Daniel Anulliero
Posts: 724
Joined: Fri Jan 04, 2013 3:55 pm
Location: Nice

Re: Simplifying code

Post by Daniel Anulliero » Mon Nov 09, 2020 11:37 am

About GUIs ,I think the more important is : feeling good with a GUI
I use Arena since long time , I like Wb too , but use Arena for my tests.
Each programmer use the prefered one , [Moderation] Please no joking at the expense of other members.

Henk
Posts: 6657
Joined: Mon May 27, 2013 8:31 am

Re: Simplifying code

Post by Henk » Tue Nov 17, 2020 1:51 pm

mvanthoor wrote:
Sun Nov 08, 2020 4:02 pm
Henk wrote:
Sun Nov 08, 2020 9:38 am
Might be WinBoard/XBoard does not exist in the future like CTF. Same may hold for Arena.
I even remember that I accidentally deleted or moved Winboard on my computer.
There will always be some other chess gui; but you are right with that one. I've been looking for engines in the 1450-1950 CCRL Elo range to test against, but many I try to download are just gone. The website doesn't exist anymore, and most have been gone so long that the WayBack machine doesn't have it on archive. The rating lists holds many engines that have been written, thrown onto github, tested one version or another, and then abandoned. Many have bugs in their output (and some don't even have any info output at all), which would make them completely useless as an analysis engine.

The same is true for many GUI's. There are lots of them, but often they're just abandoned, or development stalls for many years. Same happened to Picochess. Development was essentially halted in 2018. (That is the reason why I intend to lift the DGT E-board communication from it and start rewriting a version in Rust, some day. I intend to try and upgrade the libraries of the current version, so other people could develop this version further, but I probably won't be developing on top of it. I don't want to get into python for my personal projects.)
I also have a bad taste and I find standard settings of WinBoard look ugly. That's another reason to rewrite it.

Henk
Posts: 6657
Joined: Mon May 27, 2013 8:31 am

Re: Simplifying code

Post by Henk » Fri Nov 20, 2020 8:53 am

Refactoring sometimes far from easy. So that would be an argument to re-start from scratch.

Post Reply