Forums

PythonAnywhere editor theme

It would be nice if the code editor (IDE) on PythonAnywhere had a couple of themes, e.g. default, dark, etc. Has anyone requested this before? Or, is it editable via CSS somewhere per user environment?

Thanks

We have had a few requests for editor themes. I have upvoted the ticket for you.

Second that - the greens/aquas/blues are a bit close together! Cobalt all the way…!

Upvoted :-)

did anything ever come of this?

It's still on our list of things to do, but it's a pretty long list.

okay great, thanks for the quick response

@glenn - How about now?

Still on the list! I've added another upvote.

Chuck me in an upvote

Upvoted!

Second that. A dark theme would be a great addition.

It's not an option officially supported by PythonAnywhere, but I would use Greasemonkey scripts to change the color theme. This is already supported out of the box in chrome/chromium (you might need to install it in firefox).

Something like the following works:

// ==UserScript==
// @match https://www.pythonanywhere.com/user/*/files/*edit
// @run-at document-end
// ==/UserScript==

console.log('editor background changed by user greasemonkey script');
var editorContent = document.getElementsByClassName('ace_content')[0];
editorContent.style.backgroundColor = 'grey';

You would have to install it as an extension. (which I believe you can do by going to chrome://extensions/, enabling developer mode, and drag and dropping a myscript.user.js file over)

I can confirm this works but makes the font not very readable

indeed- you can also tweak the fond color with style.color, and customize it however you want.

One more upvote, please, for a dark theme (without Greasemonkey); perhaps Solarized Dark or Monokai. Thanks folks!

Upvoted!

Upvote please

Al

Noted :-)

upvote +cough darcula cough+ :)

upvote please! the white background kills my eyes!

Upvoted!

Upvoted!

Noted :-)

That is one hell of a long list. 3 years worth xD

Yup :-) It's not our most-requested feature, but it's getting there, especially with the current rush of posts here.

If I had to vote for an actual ACE theme for starters, I like this one.

https://github.com/ajaxorg/ace-builds/blob/master/src-noconflict/theme-pastel_on_dark.js

Yes, please :) I'm not using PA editor often, but I feel the pain of others - WHITE BACKGROUND IS THE WORST :( Also there should be an option to switch those themes (even back to original), because sometimes we may need that bad white, like when the browser already contains sort of mitigation solution - plugin or option (example - inverted colors), for the PA to not differ much from other sites.

OK -- extra upvotes noted :-)

As a temporary alternative for those who it really makes a difference to, I have found this console editor is ok, runs in a bash console on PA. Of course it is not vim or emacs.... Hope it is ok to link it.

https://github.com/zyedidia/micro

I am using micro-1.4.1-dev.77-linux64.tar.gz - seems ok.

well you can also use and customize your own vim/emacs on our consoles :D

Thanks, I looked into this and your post here:

https://blog.pythonanywhere.com/106/

Was very helpful. I have not used vim with PA because it is a muscle memory thing and some things just don't work the same in that console, so I just looked for the best lightweight other editor that didn't use too much of my valuable CPU.

I also discovered....

https://chrome.google.com/webstore/detail/secure-shell-app/pnhechapfaindjhompbnflcldabbghjo

...along the way, which I hope will make it possible to properly use vim from my chromebook. I will update how that goes when I have tested more.

Anyway - thanks for the encouragement to find a solution using vim. It is really the way forward. :)

:-)

Please add another upvote from me. The white background is rough.

Noted!

pleeaasseee...dark theme

Upvote added :-)

Another upvote from me please!

Noted! This one is going up the list quite quickly now :-)

Upvote

after 3 years I think it's about time eh? :P

you can also use Stylus extension https://github.com/openstyles/stylus

.ace_content {
  background-color: gray;
}

Dark theme please. Bump...bump...bump it up!

Bumped indeed :-)

For those who would like a dark theme, feel free to use: https://userstyles.org/styles/167372/pythonanywhere-dark-editor

It's a google chrome addon

[edit by admin: linkified]

Awesome, thanks for sharing that!

Dark theme please. I'm old and my eyes hurt :-)

Upvoted!

Upvoted

And noted :-)

Upvoted :p

noted

Any update on this?

We will let you know here.

Upvoted!! The Pythonanywhere team is awesome! :)

Thanks! I've made a note of your upvote.

+100 I can't belive its a suggestion from 2015, and now 8 years and several clone threads later they still can't save a theme preference. Also, dark theme for the general site would be much appreciated. Don't you know there are more coders who like dark themes then light? So would you kindly not kill our eyes plz?

@OZ80 thanks for the feedback! It's a pretty opinionated subject (and as far as science is concerned I think light theme is easier on the eyes), but you're pretty right there should be an option to switch to the dark mode (upvoted relevant tickets for you); as a "workaround" you can do some editing in our consoles, which have dark theme by default.