More bits of plugins and other stuff (b135)

b135

GCA should now be saving and loading the system color settings.

The System Colors dialog now supports importing colors from a prefs file.

The System Colors dialog now supports exporting colors to a prefs file. To export, you must provide a profile name so that the color scheme can be imported in the future using that name. Supports exporting to an existing prefs file without overwriting the other contents of the file, but will warn if you might overwrite system colors with the same name.

Updated the Plugins dialog to support control plugins. Enabling or disabling Unified boxes should take effect once the dialog is closed.

Updated some of the code related to disabling and managing disabled plugins to be able to better handle controls and built-in plugins.

Adjusted the setup for the Sheet Options dialog so that it will no longer accidentally include control plugins in the sheets list, as those are not intended to be included (both because controls don’t support profiles and because controls are instantiated as possibly multiple other objects with the plugin itself being more of a template).

Added more xml doc headers to various procedures in various places.

Added more explicit type conversions in more places and removed more obsolete code blocks.

Adjusted the Simple Options dialog (the one used for run-specific options for Export Sheets) to allow for it to serve as the Options dialog for the control plugins.

Updated the IUnifiedViewBox interface.

Control plugins can now raise the ShowOptions event to tell GCA to call up the Options dialog with the options sheet for that control. Once the user has interacted with the dialog and closed it, GCA will call SetOptions so that the plugin can apply any changes. Note that these plugins are welcome to manage setting of the options themselves through their own UI, and simply use the sheet options that GCA implements to persist those options between sessions. GCA will save control plugin options when it shuts down, and it loads them when it instantiates controls during startup. (These options are saved in SheetOptions.prefs, while the simple settings that GCA manages for its own use, such as visibility on the form or column spanning, are saved in gca5.prefs.)

Updated the attack modes boxes to allow setting some options through GCA’s plugin control options dialog.

Updated the sample Attack Modes Box – External plugin to allow setting some options through GCA’s plugin control options dialog.

Updated the trait list boxes to once again support turning on/off shading of alternate lines.

The Gives Builder in Simple Edit should now only appear when Show All Fields is turned on.

The Where It’s Kept section for equipment should now appear higher up the form on Simple Edit.

Moved the code for saving and loading settings for the various objects that handle user-settings into the objects themselves, where it should have been all along, instead of in GCA’s main code.

The color settings saved to prefs files has been altered slightly, so that the saved color within the brackets, if not a named one, will now use my preferred “&FF00FF” hex color format instead of the previous “Color [A=255, R=255, G=240, B=255]” format.

* Trait Lists

Added a couple lines of code to allow formatting the display of weights and dollar costs for equipment items in the equipment trait lists. I don’t yet have support for it in the UI anywhere, but in the gca5.prefs file, the entries look like this:

FormatWeights = False
WeightFormat = ##,##0.00
FormatDollarCosts = False
DollarCostFormat = ##,##0.00

Change the False to True and GCA will use the format entries for the displayed values in the equipment lists. The Format values use the .Net Format() codes (as per Microsoft.VisualBasic.Strings.Format). The defaults shown here display two decimal places for each and always show at least one digit to the left of the decimal point.

* Color Block Sheet

Updated description to refer to Unified view rather than Compact view.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.