1

I have a special family of functions used for different type of tracing and verbose output, calls to which are sprinkled throughout my code. I've given them a prefix and I often search for that prefix. However, I realized I spend so much time looking for and editing these functions that I'd like to make it a bit more streamlined if possible. I would like to add syntax highlighting to any calls to these functions so that they are easy to find.

I work in Jupyter Notebook, is it's doable to add syntax highlighting with a unique color to calls to any of a specified set of functions in Jupyter Notebooks without rewriting half of Jupyter and how would I go about it?

2 Answers 2

4

I don't know if I understand your question correctly. But if you require a addon which highlights the selected variable on Jupyter Notebook you can install the following Repo in your python/Jupyter notebook version

Jupyter Highlight Selected word

Note that you should run the jupyter nbextension enable highlight_selected_word/main on every environment you have by activating each environment and runing that command in the command line (if using Conda or other package manager)

Sign up to request clarification or add additional context in comments.

Comments

-1

If you are likely to develop many notebooks and notebook related files, I also highly recommend that you check jupyterlab. It's as simple as notebooks to install and very convenient.

1 Comment

highlight selected word is not supported on JupyterLab until now

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.