StevensDeptECE / GrailGUI

GrailGUI is a prototype of a replacement for web programming (HTTP, HTML, CSS, JavaScript) and GUI programming. It includes a client graphical API, a browser implemented in C++ and OpenGL, a protocol to transmit metadata and data in binary, a language (XDL) to describe the binary data, and local storage to retain data on the client should that be necessary. Encrypted communications (equivalent of TLS) have not yet been implemented.
GNU General Public License v3.0
7 stars 14 forks source link

Create a new solution for setting the line width of a style in graph widgets #10

Open dkrautha opened 3 years ago

dkrautha commented 3 years ago

Commit 06dbc2a reverted breaking changes I made to the constructor of Styles, but introduced problems in changing line widths in various graph widgets which relied on the aforementioned changes.

dkrautha commented 3 years ago

After starting to work on this it seems like a bit of a non issue considering that the setLineWidth exists as a function on styles, and we can just use that. The only problem is that it forces the styles created in the graph tests to be not constant, which means that they could be accidentally changed in the future.

dkrautha commented 3 years ago

After doing a bit more digging, it seems like the best solution would be to put a line width back into the constructor of Style, but make it a forced parameter. This will avoid the ambiguity that was resulting before from giving line width a default value in the constructor. It's probably best to make separate constructors including line with to prevent having to change every call to the style constructor ever.