Author Topic: CamBam Theme Manager - new plugin  (Read 389 times)

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
CamBam Theme Manager - new plugin
« on: October 30, 2020, 18:41:54 pm »
A plugin to allow CamBam's colours, as defined in Tools->Options to be easily changed and managed.
For CamBam 1.0 only

In the attached zip file are;

1. the plugin dll
2. a pdf manual which I encourage you to read first
3. a sample theme file called "Light Theme"

unzip the archive, put the dll file into CamBam's Plugins folder
put the sample theme file in CamBam's system "styles" folder, C:\ProgramData\CamBam plus 1.0\styles
put the pdf manual wherever is best for you

Then read the manual !
Edit: v1.1 attached.
1. changed the open/save path to CamBam system styles.
2. updated the pdf manual

Edit:v1.2 attached

1. file extension of theme files changed to thxml because CamBam was trying to read the previous xml extension as a styles file.
« Last Edit: November 03, 2020, 07:28:21 am by EddyCurrent »
Made in England

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 6210
    • View Profile
    • Cambam V1.0 French Doc
Re: CamBam Theme Manager - new plugin
« Reply #1 on: October 31, 2020, 04:46:48 am »
Hello

Good idea ;)

++
David

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #2 on: October 31, 2020, 11:23:24 am »
It was more of a learning exercise for me with regard to using xml and classes.
Made in England

Offline GeoffreyGRoy

  • Storm Trooper
  • ***
  • Posts: 201
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #3 on: November 01, 2020, 03:52:23 am »
Dear Eddy

Nice idea.

There is a problem with saving the config file in the standard CamBam plugins folder (i.e "c:\Program Files\Cambam plus 1.0\Plugins"), perhaps it might be better to put it (perhaps optionally)  elsewhere, perhaps "c:\Program Data\CamBam plus 1.0\styles"

Geoff

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #4 on: November 01, 2020, 10:45:22 am »
Geoff,

What is about your system that is causing that error ? I don't use drive C: for CamBam and D: works fine.
I chose the Plugins folder thinking it would be a safe bet and the other folder your mentioned might be problematic.
« Last Edit: November 01, 2020, 11:04:26 am by EddyCurrent »
Made in England

Offline GeoffreyGRoy

  • Storm Trooper
  • ***
  • Posts: 201
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #5 on: November 01, 2020, 23:00:52 pm »
Dear Eddy

The standard install folder for CamBam is in  "c:\Program Files\ " for the 64 bit version.  This folder is protected by Windows from normal user "writing".  It can be over-ridden, but this is a bit messy - you still get a warning message - and requires Administrator privileges.  If you install CamBam elsewhere it is not a problem.  This is why most CamBam settings are stored in c:\ProgramData.

Geoff

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #6 on: November 02, 2020, 08:43:53 am »
Geoff,

Thanks, I'll have a look at that, it's what I suspected.
Made in England

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #7 on: November 02, 2020, 10:45:46 am »
Version 1.1 attached to first post in this thread.

1. changed the save/open folder to CamBam system styles due to Windows' permissions issue with plugins folder.

Thank you Geoff for bringing this to my attention. It seems I knew about this from previous experience but subsequently forgot.  ???
« Last Edit: November 02, 2020, 10:59:22 am by EddyCurrent »
Made in England

Offline driedeker

  • Storm Trooper
  • ***
  • Posts: 143
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #8 on: November 02, 2020, 19:55:39 pm »
new version not working for me not sure what I have wrong but this is the error and the folder with the file in there.
Made in England in 53

Offline driedeker

  • Storm Trooper
  • ***
  • Posts: 143
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #9 on: November 02, 2020, 20:32:14 pm »
Ok it appears I put the CBTheme-Light Theme.xml in the styles folder because thats where I thought it would import it from.
as I read this

1. changed the save/open folder to CamBam system styles due to Windows' permissions issue with plugins folder.

once I deleted the theme.xml the error went away
« Last Edit: November 02, 2020, 20:35:05 pm by driedeker »
Made in England in 53

Offline driedeker

  • Storm Trooper
  • ***
  • Posts: 143
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #10 on: November 02, 2020, 21:10:25 pm »
import export folder path needs changing or a note not to use the styles folder.
imported theme from download location and it loaded and is now in the config file.
Made in England in 53

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #11 on: November 02, 2020, 21:22:17 pm »
Thanks for testing and feedback.

To import a theme file e.g. CBTheme-Light Theme.xml
1. go to CamBam menu Tools->Theme Manager
2 once the Theme Manager window opens go to it's File menu then "Import Theme", select the theme then Open.

From the error message you posted it looks like you went a different route.
Made in England

Offline GeoffreyGRoy

  • Storm Trooper
  • ***
  • Posts: 201
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #12 on: November 02, 2020, 23:25:04 pm »
Dear Eddy
Vers 1.1 is basically OK now.

 On first launch, where there is no config file existing an "error" is reported.  Once a first "Save All Changes" is executed then the problem goes away.  It might be useful to be a little more explicit in the error message, perhaps "CamBamThemes.Config file not found, please do a Save All Changes to create one", or create one quietly on first launch.

Thanks for the update.

Geoff

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 4565
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #13 on: November 03, 2020, 06:46:40 am »
@driedeker, I got that error message today, it appears CamBam is trying to open the theme file because it's extension is xml. Likely CamBam scans that folder for xml files and assumes they are all styles.

You solve one problem and create another.  ???

I'll either have to use another folder or change the extension name.

Edit: new version attached to first post in this thread.

1. The theme file extension is now thxml (theme xml)

Please delete "CBTheme-Light Theme.xml" from the styles folder and start again with the new thxml file.
The main file called, "CamBamThemes.config" is okay and that should still be left in the styles folder.
« Last Edit: November 03, 2020, 07:26:38 am by EddyCurrent »
Made in England

Offline driedeker

  • Storm Trooper
  • ***
  • Posts: 143
    • View Profile
Re: CamBam Theme Manager - new plugin
« Reply #14 on: November 03, 2020, 08:19:20 am »
The new theme file extension has sorted it.
Cheers
Made in England in 53