Skip to content
| Marketplace
Sign in
Visual Studio Code>Formatters>RTF Markdown EditorNew to Visual Studio Code? Get it now.
RTF Markdown Editor

RTF Markdown Editor

NGPowerToys

|
1,016 installs
| (1) | Free
Word-like WYSIWYG Markdown editor for VS Code — RTL/Hebrew/Arabic first, Mermaid diagrams, AI-powered PDF → Markdown via GitHub Copilot Chat, one-click HTML/DOCX/PDF import, Word/HTML/PDF export, dedicated Documents side panel, autosave.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

RTF Markdown Editor

Word-like WYSIWYG Markdown Editor for VS Code — RTL-first, Azure DevOps Mermaid, Export Word/HTML/PDF, Import Word / HTML, AI-driven PDF → Markdown (via GitHub Copilot Chat), dedicated Documents side panel, Autosave, mostly Offline

A rich text editor extension for VS Code that provides a Microsoft Word / Google Docs-like experience for Markdown files, with special emphasis on right-to-left (RTL) languages like Hebrew and Arabic, automatic saving, Mermaid diagram support, and one-click export to HTML, Word (DOCX), or PDF. Word → Markdown and HTML → Markdown imports run fully offline; PDF → Markdown is powered by GitHub Copilot Chat through the bundled PDF processing skill and the @pdfmd chat participant. A dedicated Documents Activity Bar panel lists every Markdown, PDF, DOCX, and HTML file in the workspace — single-click any of them to edit or convert.

Features

✅ Text Formatting

  • Bold (Ctrl+B)
  • Italic (Ctrl+I)
  • Underline (Ctrl+U)
  • Strikethrough
  • Inline Code
  • Superscript & Subscript (when supported in Markdown)

✅ Paragraph & Block Formatting

  • Headings: H1–H6 style selection
  • Block Quotes: Multi-level block quotes with > syntax
  • Code Blocks: Syntax-highlighted with language detection
  • Horizontal Rules: Visual separator lines
  • Line Breaks: Soft and hard breaks preserved

✅ Lists & Tables

  • Unordered Lists (bullet points)
  • Ordered Lists (numbered)
  • Nested Lists: Full nesting support
  • Tables: Create, edit, and format markdown tables with:
    • Multiple columns and rows
    • Alignment (left, center, right)
    • Header rows
    • Pipes and delimiter preservation

✅ Links & Media

  • Hyperlinks: Insert, edit, and remove links
  • Image Insertion: Support for:
    • Relative paths (local files)
    • Absolute URLs
    • Image attributes (alt text, titles)
  • Link Previews: Hover to see URLs
  • Image Scaling: Respects markdown image syntax

✅ Colors & Styling

  • Text Color Picker: Full RGB color selection
  • Highlight/Background Color: Span-level highlighting
  • Alignment Controls:
    • Left align
    • Center align
    • Right align
    • Justify (full)
  • Visual Feedback: Toolbar buttons show current formatting

✅ RTL (Right-to-Left) Language Support

  • Hebrew: Full first-class support
  • Arabic: Full support (Persian, Urdu, etc.)
  • Smart per-paragraph direction (v3.1.0): each block (paragraph / heading / list item / blockquote) picks its own dir from its content. Mix Arabic/Hebrew/Urdu prose with English code and technical terms in the same document — every line keeps the correct direction without needing <div dir="rtl"> wrappers.
  • Not "first-character" based: a sentence like React ایک بہترین لائبریری ہے correctly renders RTL even though it starts with a Latin word (fixes the Obsidian-style failure mode).
  • Smart paste: pasted content from ChatGPT / Gemini / Claude is re-evaluated line-by-line on paste — mixed-language chat responses keep their structure.
  • Manual cursor toggle (v3.1.0): Ctrl/Cmd+Shift+X or the toolbar's Cursor direction button cycles the current block through auto → LTR → RTL → auto. Lets you pick a direction in an empty paragraph before you start typing.
  • Global RTL toggle: still available — forces the whole document right-to-left when you want it.
  • RTL in Exports: direction preserved in both HTML and DOCX exports.

✅ Diagram Support

  • Mermaid Diagrams: Full integration with all Mermaid diagram types:
    • Flowcharts
    • Sequence diagrams
    • Gantt charts
    • Class diagrams
    • State diagrams
    • Entity-Relationship diagrams
    • User journey diagrams
    • Git graphs
    • Pie charts
  • Syntax: Standard ```mermaid blocks (GitHub compatible) and ::: mermaid blocks (Azure DevOps compatible)
  • Live Editing: Click any diagram to open it directly in the Mermaid NG — Visual Editor companion extension (drag-and-drop WYSIWYG canvas; v2.3.0+ opens the clicked diagram active without showing the thumbnail picker; v2.5.0+ adds a per-node + button → 4-shape picker for one-click flow building, multi-line labels with \n encoding across every object type, and a default + recently-used colour palette in the edit modal). Falls back silently to the built-in source-edit modal when the companion isn't installed — no install prompt, no broken click.
  • Bundled Renderer: No CDN required, fully offline
  • Export as PNG: Diagrams are pre-rendered to PNG for HTML and DOCX export

Companion — Mermaid NG · Diagram Files panel. Install Mermaid NG — Visual Editor and your workspace's .mmd / .mermaid files surface in their own Activity Bar panel — single-click any file to open it in the WYSIWYG canvas, the same way the RTF Markdown Editor's Documents panel works for .md / .pdf / .docx / .html.

Mermaid NG — Diagram Files side panel listing .mmd files alongside the VS Code Welcome page

✅ Export to HTML

  • One-Click Export: Toolbar button or Command Palette
  • Self-Contained: All images embedded as base64 — single portable file
  • Mermaid as PNG: Diagrams pre-rendered to PNG images (no CDN needed)
  • RTL Preserved: Right-to-left direction detected and applied
  • Fully Offline: No internet required — 100% standalone HTML output
  • Command: RTF Markdown: Convert to Web Archive (HTML)

✅ Export to Word (DOCX)

  • One-Click Export: Toolbar button (W icon), right-click context menu, or Command Palette
  • Proper .docx Format: Opens natively in Microsoft Word, LibreOffice, and Google Docs
  • Mermaid as Embedded Images: Diagrams exported as real PNG images inside the DOCX — not blank boxes
  • RTL Support: Document direction set correctly for Hebrew/Arabic content (w:bidi)
  • All Styling Preserved: Headings, tables, code blocks, lists, blockquotes
  • No External Dependencies: Built entirely with Node.js built-ins — no additional packages
  • Command: RTF Markdown: Convert to Word (DOCX)

✅ Export to PDF

  • One-Click Export: Right-click context menu or Command Palette
  • High-Quality Rendering: Uses Chrome/Chromium headless for pixel-perfect PDF output
  • Mermaid as Embedded Images: Diagrams pre-rendered to PNG before PDF generation
  • RTL Preserved: Right-to-left direction correctly applied in PDF layout
  • Metadata Embedding: Embeds original Markdown structure for lossless re-import
  • Command: RTF Markdown: Convert to PDF

✅ Export to Web Archive (HTML)

  • One-Click Export: Toolbar button, right-click context menu, or Command Palette
  • Self-Contained: All images embedded as base64 — single portable file
  • Mermaid as PNG: Diagrams pre-rendered to PNG images (no CDN needed)
  • RTL Preserved: Right-to-left direction detected and applied
  • Fully Offline: No internet required — 100% standalone HTML output
  • Command: RTF Markdown: Convert to Web Archive (HTML)

✅ Convert PDF to Markdown — via GitHub Copilot Chat

Requires GitHub Copilot Chat. PDF → Markdown is the only feature in this extension that depends on an external AI service. The menu entry is hidden unless GitHub Copilot Chat (or GitHub.copilot) is installed, and the actual conversion runs against Copilot's language models.

  • Right-Click Import: Right-click any .pdf file in the Explorer → "Convert PDF to Markdown (via GitHub Copilot Chat)" (hidden when Copilot is not installed)
  • Command Palette: RTF Markdown: Convert PDF to Markdown (via GitHub Copilot Chat)
  • Bundled PDF Skill: The extension ships resources/skills/pdf/SKILL.md — a structured prompt that drives the model's conversion behavior (heading hierarchy, GFM tables, RTL handling, bold labels, mermaid placeholders for diagram pages, etc.).
  • Chat Participant: A @pdfmd participant is registered with the VS Code Chat API. The menu opens chat and pre-invokes it with the chosen PDF; you can also type @pdfmd convert /path/to/file.pdf to markdown directly into chat.
  • Local PDF Read: Text + positions are extracted locally with pdfjs-dist before the prompt is sent — the model never has to read the file from disk. Hebrew / Arabic / CJK paths and content are all supported.
  • Chunked Send: The document is split into page-aligned chunks (40 K chars each) so the entire PDF is processed — no character-count truncation. Each chunk is sent in its own request and the responses are concatenated in order.
  • Diagrams & Images Extracted: Embedded images (architecture diagrams, sequence diagrams, charts, illustrations) are pulled out locally and saved as PNGs to .attachments/.<pdfBaseName>/image_<N>.png next to the output Markdown — the same .attachments/ convention as the DOCX importer. The final .md references them with real ![](https://github.com/NextGenPowerToys/rtf-markdown-editor/raw/HEAD/.attachments/…) links so they render inline in the RTF Markdown editor.
  • Saved Next to the PDF: The streamed Markdown is collected silently, wrapping `````markdown`` fences and pre-amble prose are stripped, and the result is written to <pdfBaseName>.md next to the original PDF, then opened in the RTF Markdown editor.
  • Chat as a Status Surface: Chat shows only progress + the final Saved Markdown to … link. The document body is never echoed there.

✅ Import from Word (DOCX → Markdown) — Content Extraction

Purpose: Extract text content from Word documents into Markdown for downstream processing by AI agents, search indexing, or content migration. This is not a 1:1 Word-to-Markdown converter — it is a content extraction tool that captures text, structure, and images, not the exact visual formatting of the original document.

  • Full Round-Trip: Export to Word, edit it, import back to Markdown
  • Right-Click Import: Right-click any .docx file in the Explorer → "Convert to Markdown"
  • Command Palette: RTF Markdown: Convert to Markdown
  • All Content Preserved: Text, headings, tables, code blocks, lists, blockquotes
  • Images Extracted: All embedded images saved as real files in .attachments/.<name>/ — no base64 blobs in your Markdown
  • Mermaid Diagrams: Exported Mermaid PNGs are imported back as image references
  • Smart Detection: Automatically handles both extension-generated DOCX files and standard Word documents
  • Correct Bullet Import: Bullet lists from standard Word documents import with proper formatting (fixes Word "List Paragraph" style artifact)
  • Offline: No external tools or internet required

✅ Import from HTML (HTML → Markdown)

Purpose: Convert standalone HTML files (web archives, exported Confluence pages, scraped documentation, etc.) into Markdown so the content can be edited in the RTF editor or fed to downstream tools.

  • Right-Click Import: Right-click any .html / .htm file in the Explorer → "Convert HTML to Markdown"
  • Command Palette: RTF Markdown: Convert HTML to Markdown
  • Documents Side Panel: A single click on an HTML entry in the side panel runs the same conversion
  • Reuses the extension's HTML→Markdown pipeline: Same turndown-based converter that powers the GFM-table rule used elsewhere
  • Saved Next to the Source: Output .md lands beside the original .html and opens in the RTF Markdown editor
  • Offline: No external tools or internet required

📁 Documents Side Panel

A dedicated Activity Bar panel that lists every supported document in the workspace and gives you one-click "open" / "convert" actions — no context-menu hunt required.

  • Activity Bar Icon: Click the RTFMD icon on VS Code's Activity Bar to open the Documents view
  • Auto-discovers every .md / .markdown / .pdf / .docx / .html / .htm file in your workspace (respects files.exclude, skips node_modules / .git / dist / out / .vscode-test)
  • Type-specific click action:
    • .md / .markdown → opens in the RTF Markdown Editor
    • .pdf → runs Convert PDF to Markdown (via GitHub Copilot Chat) — requires GitHub Copilot Chat
    • .docx → runs Convert DOCX to Markdown (offline)
    • .html / .htm → runs Convert HTML to Markdown (offline)
  • Type-specific icons + … → MD descriptions so it's obvious at a glance which entries are editable vs. convertible
  • Workspace folder layout: Single workspace folder surfaces its files at the top; multiple folders each appear as a collapsible group
  • Live refresh: A FileSystemWatcher keeps the tree in sync with creates / renames / deletes; a $(refresh) button on the view title bar forces a manual rescan
  • Welcome screen on empty workspaces with a quick "Rescan workspace" action

✅ Editor Title-Bar Quick Action

  • When a .md / .markdown file is open in any non-RTF editor (default text editor, plain vscode.open, another custom editor), the RTFMD icon appears in the top-right of the editor's title bar
  • Click it to switch the file into the RTF Markdown editor without opening a context menu
  • Hidden when the file is already in the RTF editor

🔒 Mostly Offline & Secure

  • Editor & Export Run Offline: WYSIWYG editing, autosave, and exports to Word / HTML / PDF need no network access
  • Word / HTML Import Run Offline: DOCX → MD and HTML → MD conversion both work without any external service
  • PDF → MD Uses GitHub Copilot Chat: The only feature that contacts an external service; menu entry is hidden unless GitHub Copilot Chat is installed, conversion counts toward your Copilot usage, traffic is whatever Copilot itself emits
  • All Other Dependencies Bundled Locally: No CDN, no runtime downloads, fonts/scripts/styles embedded
  • No Telemetry: No data collection or tracking by this extension
  • Strict CSP: Content Security Policy prevents external resource loading in the editor webview
  • Complete Independence: Works without VS Code Marketplace connection

✅ Autosave & Session Management

  • Event-Driven Save (No Keystroke Save): As of 2.6.0, autosave does NOT run on every keystroke. The document is persisted only at natural "done interacting" moments — this eliminates a self-echo loop through the FileSystemWatcher that was rebuilding the ProseMirror document on every save and causing embedded images to flicker mid-typing.
  • Save Triggers:
    • Editor loses focus (TipTap onBlur — e.g. clicking outside the editing surface)
    • Webview tab is hidden (visibilitychange → hidden — user switches to a different VS Code tab)
    • Webview is being torn down (pagehide / beforeunload — panel closed, VS Code reloading)
  • Self-Write Echo Guard: After our own write, the file watcher ignores its own immediate onDidChange event so the disk round-trip can't bounce back as an externalUpdate and re-render the document
  • Content Hashing: Prevents unnecessary saves if no changes made
  • No Confirmation: Seamless auto-save without dialogs
  • Preserves State: Undo/redo history maintained during save

✅ File Handling

  • Markdown Format: Always saved as standard Markdown (.md)
  • Round-Trip Preservation: Open and save without edits = identical file
  • Syntax Preservation: All original Markdown syntax preserved exactly
  • No Formatting: No unwanted reformatting or style changes
  • Relative Paths: Image and link paths handled correctly
  • UTF-8 & Multi-Encoding: Full Unicode support with automatic encoding detection:
    • Hebrew, Arabic, Persian, Urdu
    • Chinese, Japanese, Korean
    • Emojis and special characters
    • UTF-8 / UTF-16LE / UTF-16BE / ISO-8859-1 / Windows-1252

Installation

  1. Open VS Code
  2. Go to Extensions (Ctrl+Shift+X)
  3. Search for "RTF Markdown Editor"
  4. Click Install

Usage

Opening a File

  1. Right-click a .md file in the Explorer
  2. Select "Edit with RTF Markdown Editor"
  3. The file opens in a custom editor tab

Exporting to HTML

  1. Open a .md file in the RTF Markdown Editor
  2. Click the archive icon in the toolbar, OR right-click the file in Explorer → "Convert to Web Archive (HTML)", OR
  3. Open Command Palette (Ctrl+Shift+P) → "RTF Markdown: Convert to Web Archive (HTML)"
  4. Choose a save location
  5. The exported HTML opens automatically in your default browser
  6. The exported file is a single self-contained HTML with:
    • All styling embedded
    • Mermaid diagrams pre-rendered as PNG images
    • Local images embedded as base64
    • RTL/LTR direction preserved
    • No internet required to view

Exporting to Word (DOCX)

  1. Open a .md file in the RTF Markdown Editor
  2. Click the W document icon in the toolbar, OR right-click the file in Explorer → "Convert to Word (DOCX)", OR
  3. Open Command Palette (Ctrl+Shift+P) → "RTF Markdown: Convert to Word (DOCX)"
  4. Choose a save location
  5. The exported .docx opens automatically in Microsoft Word (or your system default)

The exported document preserves:

  • All headings, paragraphs, and text formatting
  • Tables with borders and shading
  • Code blocks styled as monospace
  • Mermaid diagrams as embedded PNG images
  • RTL text direction for Hebrew/Arabic documents

Importing from Word (DOCX) — Content Extraction

Extracts text content from Word documents into Markdown. Designed for AI analysis, content migration, and search indexing — not for reproducing the exact visual layout of the original document.

From Explorer (easiest):

  1. Right-click a .docx file in the VS Code Explorer
  2. Select "Convert to Markdown"
  3. Choose where to save the resulting .md file
  4. The file opens automatically in the RTF Markdown Editor

From Command Palette:

  1. Open Command Palette (Ctrl+Shift+P) → "RTF Markdown: Convert to Markdown"
  2. Pick the .docx file to import
  3. Choose where to save the resulting .md file
  4. The file opens automatically in the RTF Markdown Editor

What gets extracted:

  • All text content: headings, paragraphs, tables, lists, code blocks, blockquotes
  • Embedded images saved as real files in .attachments/.<name>/ (referenced by relative path)
  • Mermaid diagrams (from extension-exported DOCX) imported as PNG image references
  • RTL text direction preserved

Round-trip workflow: .md → Export as DOCX → Import as Markdown → .md

Converting PDF to Markdown — via GitHub Copilot Chat

Prerequisite: GitHub Copilot Chat must be installed and signed in. The PDF → Markdown command is gated on Copilot's presence and only appears in the Explorer context menu when Copilot is available. All other features of this extension still run fully offline; only this command talks to a language model.

From Explorer (easiest):

  1. Right-click a .pdf file in the VS Code Explorer
  2. Select "Convert PDF to Markdown (via GitHub Copilot Chat)"
  3. Confirm the modal — the extension extracts the PDF text locally, opens chat, and invokes the bundled @pdfmd participant
  4. When the model finishes, the resulting <filename>.md is saved next to the source PDF and opened in the RTF Markdown Editor

From Command Palette:

  1. Open Command Palette (Ctrl+Shift+P) → RTF Markdown: Convert PDF to Markdown (via GitHub Copilot Chat)
  2. Pick the .pdf file to convert
  3. Confirm the modal
  4. The resulting <filename>.md is saved next to the source PDF and opened in the editor

From chat (direct):

  • Type @pdfmd convert /path/to/file.pdf to markdown in the Copilot Chat input. Paths with spaces, Hebrew, CJK, or other Unicode work either bare, in double quotes, or wrapped in backticks.

How it works:

  • The extension ships a PDF processing skill at resources/skills/pdf/SKILL.md. The chat participant loads it on every invocation as the model's authoritative guide for headings/lists/tables/RTL handling.
  • Text + positional data are extracted locally with pdfjs-dist — Copilot never has to read the file from disk.
  • Embedded images are pulled out at the same time and written as PNGs to <mdDir>/.attachments/.<pdfBaseName>/image_<N>.png. The prompt to the model marks each image's location on its page with an [IMAGE: <relative_path>] line so Copilot places a real ![](https://github.com/NextGenPowerToys/rtf-markdown-editor/raw/HEAD/…) reference at the right structural position. This mirrors the DOCX importer's attachment layout.
  • The PDF is split into page-aligned chunks (~40 K chars each) so the entire document is processed; nothing is truncated.
  • Each chunk is sent to Copilot in its own request along with the skill; the streamed responses are concatenated, sanitised (any wrapping ```markdown fence stripped), saved to <pdfBaseName>.md, and the file is opened in the RTF Markdown Editor.
  • Chat is a status surface only — progress messages while converting + a single final "Saved Markdown to …" link. The document body itself is not echoed into chat.

Import Philosophy & Limitations (Word & PDF)

These are content extraction tools, not format converters. The goal is to pull the textual content and document structure out of Word and PDF files into clean Markdown — so you can feed it to AI agents, run analysis, build search indexes, or migrate content into a Markdown-based workflow. They are not designed to reproduce the exact visual appearance of the source document.

Word (DOCX) import — what to expect:

  • Text, headings, tables, lists, code blocks, and blockquotes are extracted faithfully
  • Images are saved as separate files and referenced in the Markdown
  • Complex layouts (multi-column, text boxes) may not convert perfectly
  • Advanced Word formatting (tracked changes, comments, footnotes) is not preserved
  • Embedded OLE objects and ActiveX controls are skipped

PDF → Markdown (Copilot) — what to expect:

  • The extension extracts text + positions locally with pdfjs-dist, then hands the per-page text dump to GitHub Copilot Chat along with the bundled PDF skill. The model reconstructs structure (headings, lists, tables, bold labels, RTL reading order) from the positional dump.
  • Embedded images become real attachments. Diagrams and other raster images in the PDF are extracted locally and written to .attachments/.<pdfBaseName>/image_<N>.png next to the output Markdown; the final .md references them with ![](https://github.com/NextGenPowerToys/rtf-markdown-editor/raw/HEAD/.attachments/…) links — the same convention as the DOCX importer, so attachments work identically across both flows.
  • Result quality depends on the model behind Copilot Chat. A current Copilot Premium model handles the easysend.pdf reference document (Hebrew, mixed Latin, nested numbered sections, tables, embedded diagrams) to near-parity with a hand-crafted Markdown version.
  • Requires GitHub Copilot Chat — the menu entry is hidden when Copilot isn't installed and the command refuses to run.
  • Counts toward your Copilot usage. Long PDFs are chunked and sent in multiple LM requests; this is regular Copilot Chat traffic.
  • Scanned/image-only PDFs have no extractable text, so Copilot has nothing to convert from text. Embedded images on those pages are still extracted into .attachments/ and referenced from the Markdown, but textual content within the scan won't be transcribed — run those through an external OCR step first if you need the words.
  • Diagrams that were rendered to images at PDF export time are preserved as image references rather than reconstructed as live mermaid source — that would need a vision-capable model.

Toolbar Controls

Text Formatting

  • B — Bold (Ctrl+B)
  • I — Italic (Ctrl+I)
  • U — Underline (Ctrl+U)
  • S — Strikethrough
  • code — Inline code

Paragraph Styles

  • Dropdown to select: Paragraph, H1–H6

Alignment

  • ◄ — Align left
  • ◄► — Align center
  • ► — Align right
  • ◄ ► — Justify

Lists

  • • List — Bullet list
  • 1. List — Ordered list

Blocks

  • ❝ — Block quote
  • { } — Code block

Colors & Highlight

  • Color picker for text color
  • Color picker for highlight/background color

Insert

  • 🔗 — Insert link
  • 🖼️ — Insert image (relative paths)
  • ⊞ — Insert table
  • ─ — Insert horizontal rule

Export & Direction

  • Archive icon — Export Self-Contained HTML
  • W icon — Export as Word Document (DOCX)
  • RTL — Toggle RTL/LTR mode

Mermaid Diagrams

The editor supports both standard Markdown and Azure DevOps Wiki syntax:

Standard Markdown (Triple Backticks):

```mermaid
graph TD
  A[Start] --> B[Process]
  B --> C[End]
```

Azure DevOps Wiki (Triple/Quad Colons):

:::: mermaid
graph TD
  A[Start] --> B[Process]
  B --> C[End]
::::

Format Preservation: The editor preserves the original fence format on save.

To edit a diagram:

  1. Click on the diagram in the editor
  2. Edit the Mermaid source in the modal
  3. Click Save

Export Support: Diagrams are pre-rendered to PNG images in both HTML and DOCX exports — fully offline, no CDN required.

Math Formulas (Partially Supported)

Block math:

$$\frac{a}{b}$$

Inline math:

This is inline $x^2$ math.

Limitations:

  • ⚠️ HTML list wrapping with complex inline math may break across lines
  • ⚠️ Hebrew/Arabic text inside math mode (\text{}) is not supported — use English only

Autosave

The editor automatically saves your work:

  • 750ms after you stop typing
  • When the editor loses focus (blur)
  • When the tab is hidden
  • When the file is closed

Content hashing prevents unnecessary saves if no changes were made.

RTL (Right-to-Left) Languages

The editor auto-detects Hebrew and Arabic content and switches to RTL mode automatically.

To toggle RTL/LTR manually:

  • Click the RTL button in the toolbar

RTL is fully preserved in both exported HTML and DOCX files.

Code Formatting

All code (inline and code blocks) always uses left alignment, regardless of RTL/LTR mode — following universal programming conventions.

File Format

Files are always saved in Markdown format. The editor:

  1. Converts Markdown → HTML when opening
  2. Edits as WYSIWYG HTML
  3. Converts HTML → Markdown when saving
  4. Preserves all original Markdown syntax

Keyboard Shortcuts

  • Ctrl+Z — Undo
  • Ctrl+Shift+Z — Redo
  • Ctrl+B — Bold
  • Ctrl+I — Italic
  • Ctrl+U — Underline
  • Ctrl+A — Select all
  • Ctrl+C — Copy
  • Ctrl+V — Paste

Offline Mode

This extension is designed to work completely offline:

  • ✅ No internet connection required
  • ✅ No CDN dependencies
  • ✅ No remote font loading
  • ✅ Mermaid library bundled locally
  • ✅ All fonts are system fonts
  • ✅ HTML export is fully self-contained
  • ✅ DOCX export needs no external tools

The extension will function even with the network completely disabled.

Security

  • Strict Content Security Policy (CSP): Prevents inline scripts, unsafe eval
  • Webview URI Sandboxing: All assets loaded via webview.asWebviewUri()
  • No unsafe-eval: Extension code is pre-compiled, no runtime code generation
  • Local-only: No data is sent to external servers

Troubleshooting

Editor doesn't appear

  • Ensure VS Code is at least version 1.85.0
  • Close and reopen the file
  • Reload the VS Code window (Ctrl+R)

Markdown not rendering correctly

  • Check that the file is saved (Ctrl+S)
  • Verify the Markdown syntax
  • Try closing and reopening the file

Mermaid diagrams not showing

  • Check the Mermaid syntax using the official Mermaid documentation
  • Both ```mermaid and ::: mermaid syntax are supported
  • Try clicking the diagram to edit and re-save

Imported DOCX is missing content

  • Ensure the .docx was saved properly and is not password-protected
  • For extension-generated DOCX files, the import reads the internal afchunk_N.htm entries — if the file was modified by a third-party tool it may fall back to the mammoth path
  • Images are saved to .attachments/.<name>/ beside the output .md file — check that folder exists after import

Mermaid diagrams blank in exported DOCX

  • Ensure you have the file open in the RTF Markdown Editor (not just a text editor); the toolbar button, context menu, and Command Palette all use the same rendering pipeline
  • If exporting via Command Palette with the file not yet open, the editor will open in the background automatically before exporting

RTL text not displaying correctly

  • The editor auto-detects Hebrew/Arabic — ensure the content includes those characters
  • Toggle RTL manually with the RTL button in the toolbar

Technical Stack

  • Framework: VS Code Extension API
  • Language: TypeScript
  • Editor: TipTap (ProseMirror)
  • Markdown: markdown-it
  • Diagrams: Mermaid (bundled locally)
  • DOCX: Custom Open XML builder (no external library)
  • PDF Import: pdfjs-dist + Tesseract.js OCR with structure analysis
  • PDF Export: Puppeteer (Chrome headless) rendering
  • Build: esbuild
  • Runtime: Node.js (extension host), Browser (webview)

Development

Build

npm install
npm run build

Watch Mode

npm run watch

Debug

  1. Open the folder in VS Code
  2. Press F5 to start the debug session
  3. Edit code and changes will reload automatically

Contributing

Contributions are welcome! Please:

  1. Fork the repository
  2. Create a feature branch
  3. Submit a pull request

License

MIT

Support

For issues, feature requests, or questions:

  • Open an issue on GitHub
  • Check existing issues for similar problems
  • Provide details about your environment and steps to reproduce

RTF Markdown Editor — A mostly-offline, RTL-first, WYSIWYG Markdown editor for VS Code. AI-powered PDF → Markdown via GitHub Copilot Chat. One-click HTML / DOCX / PDF import, Word / HTML / PDF export, Mermaid diagrams, dedicated Documents side panel — all from one extension.

Tags

markdown editor · markdown-editor · wysiwyg · wysiwyg markdown editor · vs code extension · vscode extension · vscode markdown editor · rtl markdown · hebrew markdown · arabic markdown · bidi · mermaid · mermaid editor · flowchart · azure devops wiki · github copilot · copilot chat · chat participant · @pdfmd · ai markdown · language model api · pdf to markdown · pdf to md · ai pdf converter · ai pdf to markdown · convert pdf to markdown · docx to markdown · word to markdown · html to markdown · html converter · document converter · document management · documents side panel · file tree · technical writing · documentation · markdown editor for documentation · autosave · offline editor · rfc 7763 · attachments · image extraction

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft