Skip to content

Commit 856f552

Browse files
committed
updated readme
1 parent bae9b46 commit 856f552

File tree

3 files changed

+21
-7
lines changed

3 files changed

+21
-7
lines changed

addon/globalPlugins/MathCAT/MathCAT.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,11 @@ class MathCATInteraction(mathPres.MathInteractionNVDAObject):
223223
# log.info("2**** MathCAT registering data formats:
224224
# CF_MathML %x, CF_MathML_Presentation %x" % (CF_MathML, CF_MathML_Presentation))
225225

226-
def __init__(self, provider=None, mathMl: str | None = None):
226+
def __init__(
227+
self,
228+
provider: mathPres.MathPresentationProvider = None,
229+
mathMl: str | None = None
230+
):
227231
super(MathCATInteraction, self).__init__(provider=provider, mathMl=mathMl)
228232
if mathMl is None:
229233
self.initMathML = "<math></math>"

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ exclude = [
9595
# Tell pyright where to load python code from
9696
extraPaths = [
9797
"./addon",
98-
"../NVDA/source",
98+
"../nvda/source",
9999
]
100100

101101
# General config

readme.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -214,8 +214,18 @@ Note: there is now an option to get Vietnam's braille standard as braille output
214214
* Translations to Indonesian and Vietnamese
215215

216216
## Development Environment
217-
We include here a few important notes for setting up a development environment for working on this project.
218-
* The configuration in `.vscode/settings.json` assumes that a virtual environment has been set up in a directory named `.venv`.
219-
This virtual environment should have `pyright` and `ruff` installed, and should use Python 3.11 (32-bit).
220-
* The relative path `../NVDA/source` is included in the pyright configuration in `pyproject.toml` to enable typechecking functions from the main NVDA repository.
221-
For this to function as expected, the main NVDA repository (https://github.com/nvaccess/nvda) should be cloned into the same directory as this repository.
217+
How to set up your developer environment:
218+
1. Install Python 3.11 (32-bit).
219+
1. Set up your virtual environment.
220+
* `python -m venv .venv`
221+
1. Install python dependencies to `.venv`.
222+
* Activate the virtual environment
223+
`.venv\\Scripts\\activate`
224+
* Install lint dependencies
225+
`pip install .`
226+
1. Import NVDA code.
227+
* NVDA source code needs to be discoverable to get type hints, namespace resolution, code completion, and other IDE hints.
228+
* The relative path `../nvda/source` is included in the pyright configuration in `pyproject.toml`.
229+
* The [NVDA repository](https://github.com/nvaccess/nvda) should be cloned into the same parent directory.
230+
i.e. as a sibling to this repository.
231+
Alternatively, update `../nvda/source` in `pyproject.toml` to another location where the NVDA repository has been cloned.

0 commit comments

Comments
 (0)