Skip to content
Open
32 changes: 32 additions & 0 deletions .markdownlint-cli2.jsonc
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// A part of NonVisual Desktop Access (NVDA)
// Copyright (C) 2025 NV Access Limited
// This file may be used under the terms of the GNU General Public License, version 2 or later, as modified by the NVDA license.
// For full terms and any additional permissions, see the NVDA license file: https://github.com/nvaccess/nvda/blob/master/copying.txt
//
// Configuration of markdownlint-cli2, also used by markdownlint for VS Code
// Lint rules are inherited from .markdownlint.jsonc
{
// Ignore files specified in .gitignore
"gitignore": true,
// Lint *.md files recursively
"globs": [
"**.md",
// Our copying file is actually markdown
"copying.txt"
],
// Don't lint the following globs
"ignores": [
// Git submodules
".vscode",
"include/*/**",
"miscDeps/",
// Issue/PR templates
".github/ISSUE_TEMPLATE/",
".github/PULL_REQUEST_TEMPLATE/",
".github/PULL_REQUEST_TEMPLATE.md",
"projectDocs/issues/securityAdvisoryTemplate.md",
// Old markdown files used for testing
"tests/markdownTranslate/",
"addon/docs/"
]
}
33 changes: 33 additions & 0 deletions .markdownlint.jsonc
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
// A part of NonVisual Desktop Access (NVDA)
// Copyright (C) 2025 NV Access Limited
// This file may be used under the terms of the GNU General Public License, version 2 or later, as modified by the NVDA license.
// For full terms and any additional permissions, see the NVDA license file: https://github.com/nvaccess/nvda/blob/master/copying.txt
//
// Markdown linting rules.
{
// Use ATX style headings. E.g.
// # This is a heading
"heading-style": {
"style": "atx"
},
// Don't complain about using tabs in markdown
"hard_tab": false,
// Don't complain about lines being too long
"line-length": false,
// Only complain about repeated headings in the same part of the document outline
// Needed for the changelog
// We could consider enabling this on a file-by-file basis
"no-duplicate-heading": {
"siblings_only": true
},
// Several of our markdown files include trailing punctuation in headings
"no-trailing-punctuation": false,
// Rule is incompatible with the anchor style we use in the user guide
"link-fragments": false,
// Many of our code blocks lack a language
// This should probably be fixed gradually
"fenced-code-language": false,
"ul-style": {
"style": "asterisk"
}
}
71 changes: 2 additions & 69 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ci:
# Can't run licenseCheck as it relies on telemetry,
# which CI blocks.
# Pyright does not seem to work in pre-commit CI
skip: [checkPo, scons-source, checkPot, unitTest, licenseCheck, pyright]
skip: [pyright]
autoupdate_schedule: monthly
autoupdate_commit_msg: "Pre-commit auto-update"
autofix_commit_msg: "Pre-commit auto-fix"
Expand All @@ -36,13 +36,9 @@ repos:
hooks:
# Prevents commits to certain branches
- id: no-commit-to-branch
args: ["--branch", "master", "--branch", "beta", "--branch", "rc"]
args: ["--branch", "main"]
# Checks that large files have not been added. Default cut-off for "large" files is 500kb.
- id: check-added-large-files
# POFiles and TTF fonts can't be made smaller
exclude_types: ["pofile", "ttf"]
# Same applies for NVDA dictionary (.dic) files and Spline Font Database (.SFD) files, but these aren't recognised by the Identify library.
exclude: "\\.(dic|sfd)$"
# Checks python syntax
- id: check-ast
# Checks for filenames that will conflict on case insensitive filesystems (the majority of Windows filesystems, most of the time)
Expand All @@ -65,31 +61,10 @@ repos:
- id: check-toml
# Validates YAML files.
- id: check-yaml
# Validates XML files.
- id: check-xml
# Ensures that links to lines in files under version control point to a particular commit.
- id: check-vcs-permalinks
# Avoids using reserved Windows filenames.
- id: check-illegal-windows-names
# Checks that tests are named test_*.py.
- id: name-tests-test
args: ["--unittest"]
# Exclude Python files under `tests/` that aren't unittest files.
# This is a Python verbose regular expression.
# See https://docs.python.org/3/library/re.html#re.VERBOSE
exclude: |
(?x)^tests/(
checkPot.py | # Doesn't use unittest
system | # Uses robot
unit/ (
# Test helpers
textProvider.py |
extensionPointTestHelpers.py |
objectProvider.py |
test_speechManager/speechManagerTestHarness.py
)
)

- repo: https://github.com/asottile/add-trailing-comma
rev: v3.2.0
hooks:
Expand All @@ -114,51 +89,9 @@ repos:
- id: pyright
name: Check types with pyright
additional_dependencies: [ "pyright[nodejs]==1.1.406" ]

- repo: https://github.com/astral-sh/uv-pre-commit
rev: 0.8.4
hooks:
- id: uv-lock
name: Verify uv lock file
# Override python interpreter from .python-versions as that is too strict for pre-commit.ci
args: ["-p3.13"]

- repo: https://github.com/DavidAnson/markdownlint-cli2
rev: v0.18.1
hooks:
- id: markdownlint-cli2
name: Lint markdown files
args: ["--fix"]

- repo: local
hooks:
- id: checkPo
name: Check po files
entry: uv run source/l10nUtil.py checkPo
language: python
types: [pofile]
- id: scons-source
name: build c/c++ files
entry: cmd.exe /c "scons source --all-cores"
language: system
pass_filenames: false
types_or: [c, c++]
- id: checkPot
name: translation string check
entry: cmd.exe /c "scons checkPot --all-cores"
language: system
pass_filenames: false
types: [python]
files: ^source/.*$
- id: unitTest
name: unit tests
entry: ./rununittests.bat
language: script
pass_filenames: false
types_or: [python, c, c++, batch]
- id: licenseCheck
name: Check license compatibility of pip dependencies
files: ^(runlicensecheck\.bat|pyproject\.toml)$
entry: ./runlicensecheck.bat
language: script
pass_filenames: false
61 changes: 3 additions & 58 deletions addon/doc/ar/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,73 +9,18 @@ you want to join sections of text together ready for pasting. The clipboard
content can also be cleared.

## مفاتيح الاختصار ##
* NVDA+windows+c: Add selected text, Unicode braille characters which
represent MathML objects, or the string which has been marked with the
review cursor, to the clipboard.
* NVDA+windows+x: لمسح محتوى الحافظة
* NVDA+windows+f9: Mark the current position of the review cursor as the start of the text to be added to the clipboard. If you use nvda+F9, the text will not be added.
* Not assigned: Copies to (or cuts from) the clipboard, with the possibility of being asked for a previous confirmation.

* VDA+windows+f9: Mark the current position of the review cursor as the start of the text to be added to the clipboard. If you use nvda+F9, the text will not be added.
* Not assigned: Copies to (or cuts from) the clipboard, with the possibility of being asked for a previous confirmation.

ملحوظة: يمكنك تغيير الاختصارات المذكورة أعلاه من خلال الذهاب إلى قائمة NVDA
الرئيسية, ثم قائمة التفضيلات, ثم تخصيص اختصارات NVDA, ثم فئة استعراض النص.

## قائمة التفضيلات ##
* Clip Contents Designer settings: Allows to set a separator which can be used to find the text segments once the entire added text is pasted.
It's also possible to choose if the added text will be appended or prepended, if available actions (add, clear clipboard, emulate copy and emulate cut) should be performed inmediately or after confirmation, and if confirmations will be requested just if text is contained in the clipboard.

Notes:

* The above command can be changed from NVDA menu, Preferences submenu,
Input gestures dialog, Configuration category.
* Confirmations won't be requested when a message box of NVDA is still
opened. In those cases, actions will be inmediately performed

## Changes for 7.0

* In the dialog to configure the Emulate copy and Emulate cut
functionalities at installation, if you choose no, the commands for these
features will be removed, so that you can restore the normal behavior for
control+c and control+x.

## Changes for 6.0

* Added options to choose if available actions should be performed after confirmation.
* Added Emulate copy and Emulate cut commands, which could be assigned from the Input gestures dialog.
* Added a dialog to configure the Emulate copy and Emulate cut functionalities at installation. This allows to add the control+c and control+x commands to copy and cut, and be asked if you want to replace the clipboard contents when pressing these keystrokes.
* Fixed documentation for script_add (Windows+NVDA+c).

## Changes for 5.0 ##

* The visual presentation of the dialog has been enhanced, adhering to the
appearance of the dialogs shown in NVDA.
* Requires NVDA 2016.4 or later.

## Changes for 4.0 ##
* Add-on settings are managed from NVDA configuration, so that standard
profiles can be used to save different separators, and it's not needed to
copy the settings for importing at reinstallation.
* Now it's possible to choose if the added text will be appended or
prepended, using the Add text before clip data check box from the Clip
Contents Designer settings dialog.

## مستجدات الإصدار 3.0 ##
* Braille representation of MathML objects can be added to the clipboard if
MathPlayer is installed.
* If no separator is set, just a single line will be placed between the
added text segments.
* يمكن تعيين اختصار لفتح محاورة إعدادات الإضافة.
* إضافة مربع تحديد لإعدادات الإضافة, للاختيار ما إذا كان ينبغي نسخ الفاصل
بين القطع النصية لاستيراده عند إعادة تثبيت الإضافة

## مستجدات الإصدار 2.0 ##
* Hindi characters can be used as the separator between added contents.

## مستجدات الإصدار 1.0 ##
* إصدار أولي

[[!tag dev stable]]
[[!tag dev]]

[1]: http://addons.nvda-project.org/files/get.php?file=ccd

[2]: http://addons.nvda-project.org/files/get.php?file=ccd-dev
Loading