Page 1 of 2

Color theme support doesn't work after installation

Posted: Sat Jun 01, 2019 5:41 pm
by shadowsocks
Updating 12.0 to 13.0

Startup. Codes are displayed in plain text.
Image

After clicking the "Yes" button below, and agreed to restart CL, nothing changed. Still the same message popped out.

Tried to shift to c++ highlighting:
Image
After clicking "Language", the language list didn't pop out.

Color theme list in "colors and fonts settings" is empty, and importing theme ZIP file didn't work either.

Can anyone help? Thanks a lot!
OS is Windows 10.

Re: Color theme support doesn't work after installation

Posted: Sun Jun 02, 2019 9:52 am
by eranif
Looks like a corrupted configuration file somewhere.
Can you try this:

- Close CodeLite
- Rename the folder %appdata%\CodeLite into something else (e.g. %appdata%\CodeLite.backup)
- Start CodeLite

Let me know how it worked out for you

Thanks!

Re: Color theme support doesn't work after installation

Posted: Sun Jun 02, 2019 10:51 am
by shadowsocks
It doesn't help, installing again doesn't either. Seems that once I restart CL, everything is reset. Maybe I should move back to 12.0 or try compiling CL myself?
Thank you all the same!

Re: Color theme support doesn't work after installation

Posted: Sun Jun 02, 2019 11:10 am
by eranif
Few more things to check:
- Do you have anything in the log file? (%appadata%\CodeLite\codelite.log)
- Do you have any entries in Settings->Fonts and colours?
- What happens when you hit the 'Reload default Settings' button in toolbar at the top of the 'Settings->Colours and fonts' dialog? Does it restore the colours?

It might be a permission issue (CodeLite is unable to write configuration files properly)
Checking the log might give some insights

Re: Color theme support doesn't work after installation

Posted: Sun Jun 02, 2019 11:17 am
by shadowsocks
Restore default worked, but after restarting everything went back again.
Before restoring, the theme list was empty.
Seems that it's indeed a permission issue. There're a bunch of reports about being unable to open files in .log
I found that all folders in /appdata/Roaming/codelite are read only. Does that matter?

Re: Color theme support doesn't work after installation

Posted: Mon Jun 03, 2019 5:11 pm
by shadowsocks
I'll be very grateful if someone could tell me how to solve the permission issue... have worked on it for days.

Code: Select all

[20:14:53:098 ERR] [Main] Failed to open file: C:\Users\\AppData\Roaming\codelite\config\ColoursAndFonts.conf . No error
[20:14:53:113 ERR] [Main] Failed to open file: C:\Users\\AppData\Roaming\codelite\lexers\lexers.json . No error
These are two of the entries in the .log file. All entries are all alike.
Restarting the application resets everything, as some files in AppData, for some reason, can't be modified by CL.
I wrote a simple .exe program to modify a file that CL failed to modify, and succeeded. That's strange.
When logged in to windows 10 with user Administrator and started CL, no such problem occurred. When logged in with my account (have admin access), however, the problem occurred.
Restoring to default settings (in CL settings) worked temporarily, that is, before i restarted CL again.

Re: Color theme support doesn't work after installation

Posted: Mon Jun 03, 2019 5:22 pm
by eranif
This is the default configuration location (C:\Users\AppData\Roaming\codelite\)
CodeLite accepts "-d" switch, so you can pass a different location for the settings.
So you can edit CodeLite shortcut to run something like this:

C:\Program Files\CodeLite\codelite.exe -d C:\Path\to\writable-location\codelite

Note that the configuration files will be written directly under C:\path\to\writable\location\codelite, this is why I added the `codelite` part to the path, so the path is made "unique"

Let me know how it worked out for you

Re: Color theme support doesn't work after installation

Posted: Mon Jun 03, 2019 5:42 pm
by shadowsocks
Generally it worked. After changing the directory, CL can successfully write configuration files.
Still some minor problems:
1. importing color theme from .zip doesn't work, instead I manually copied lexer.json file into the corresponding folder. That worked.
2.Every time at startup, CL runs the setup wizard again.
3.After changing some settings, CL automatically restarts itself. However, the restarted process runs in the default directory, which is useless. As a result, i'm not able to enable that "better editor colour theme support". Is there some way to change the directory permanently?
4.Some plugins like abbreviation can't work. Seems that abbreviation can't read config/abbreviation.conf correctly, or does it simply read the one in default directory?

No message in log file.

Thanks a ton for your help, and i love Codelite!

Re: Color theme support doesn't work after installation

Posted: Mon Jun 03, 2019 7:52 pm
by eranif
2. This sounds like CodeLite is still unable to write the configuration files properly. Try opening the file: config/codelite.conf under the new configuration folder and search for the string: "BootstrapCompleted" if you don't see it there, then CodeLite is unable to write to the file. You can try and add it manually (its a simple JSON file), at the top of the file, under the General section: "General": {...}

Add this line:

Code: Select all

"BootstrapCompleted": true,
3. This is indeed a bug (which I noticed a week ago :))

4. I suspect that this is related

Re: Color theme support doesn't work after installation

Posted: Thu Jun 13, 2019 8:21 pm
by eranif
The restart issue is now fixed