retext-project / retext

ReText: Simple but powerful editor for Markdown and reStructuredText
GNU General Public License v2.0
1.89k stars 196 forks source link

Issue displaying checkboxes in html with markdown-checklist extension #591

Closed wtbutler closed 2 years ago

wtbutler commented 2 years ago

I have installed the markdown-checklist extension pip3, and I have added it to my markdown file. If I check the HTML generated by ReText, it clearly includes checkboxes. I copied and pasted this into its own file and viewed it in my browser and it did include checkboxes.

<!-- Required extensions: markdown_checklist.extension -->

# TODO
 - [X] Testing  
 - [ ] This  
<!doctype html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="generator" content="ReText 8.0.0">
<title>README</title>
</head>
<body>
<!-- Required extensions: markdown_checklist.extension -->

<h1>TODO</h1>
<ul class="checklist">
<li><input type="checkbox" disabled checked> Testing  </li>
<li><input type="checkbox" disabled> This  </li>
</ul>

</body>
</html>

However, the retext preview shows no checkboxes, and when exported to a PDF, the PDF also includes no checkboxes. image

I'm using debian 11 and retext 8.0.0.

Thanks for any help!

mitya57 commented 2 years ago

Please try enabling the WebEngine renderer from the Edit menu. The default renderer supports only a basic subset of HTML.

wtbutler commented 2 years ago

Thanks for the reply! I probably did something wrong, because the option is grayed out. I tried installing chromium and restarting ReText and it's still grayed out.

mitya57 commented 2 years ago

Then try this:

sudo apt install python3-pyqt6.qtwebengine libqt6webenginecore6-bin

These packages are recommended by retext.

wtbutler commented 2 years ago

Just so I don't bork things, I'm not seeing those packages. I'm seeing pyqt5, but not pyqt6. Is there a significant enough difference that I should figure out how to get to pyqt6?

mitya57 commented 2 years ago

Sorry, I did not read your post carefully enough and I thought you installed ReText from Debian testing packages.

But you are using Debian 11 which indeed does not have PyQt6.

Then I assume you installed ReText using pip. In that case, you need this:

pip install PyQt6-WebEngine

Sorry again for confusion.

wtbutler commented 2 years ago

All good! Thanks again. That did display checkboxes. There's a separate issue now, but that seems to be with checkbox-extension and nested lists, not ReText, so this seems to be resolved!

mitya57 commented 2 years ago

Good! Closing then.