Comments (16)
Interestingly when triggering QuickLook via Terminal the scrolling works
qlmanage -p /Users/myUser/path/to/Scrolling\ Demo.md
Testing Quick Look preview with files:
/Users/myUser/path/to/Scrolling Demo.md
2022-03-21 12:35:46.902 qlmanage[39935:1023163] *** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) 'Permission denied', port = 0x8c13, name = 'com.apple.coredrag'
See /usr/include/servers/bootstrap_defs.h for the error codes.
2022-03-21 12:35:46.974 qlmanage[39935:1023163] *** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) 'Permission denied', port = 0xc01b, name = 'com.apple.tsm.portname'
See /usr/include/servers/bootstrap_defs.h for the error codes.
2022-03-21 12:36:02.005 qlmanage[39935:1023176] Persistent UI failed to open file file:///Users/myUser/Library/Saved%20Application%20State/com.apple.quicklook.qlmanage.savedState/window_1.data: No such file or directory (2)
QuickLook window differences whether triggered via Finder or Terminal
from qlmarkdown.
The bug is only for long documents? Can you share a .md file?
There are no API to control the buttons in the Quick Look title window (also the title is not customizable before macOS 12). The buttons (and the "debug" title prefix) are automatically inserted by qlmanage
.
from qlmarkdown.
I suggest you try to convert the markdown file to html with the utility:
/Applications/QLMarkdown.app/Contents/Resources/qlmarkdown_cli /Users/myUser/path/to/Scrolling\ Demo.md -o /Users/myUser/path/to/Scrolling\ Demo.html
The try to view the generated html with the Quick Look. If the bug still occurs it means that it is not due to my application but to what problem of your system (the preview of html files is always managed by the operating system).
from qlmarkdown.
Closing this for now as a false alarm
Just experienced something really mysterious. Probably we will never know how to explain this.
I used your qlmarkdown_cli
but unintentionally used the same file for input and output, hence overwrote the MD with the HTML. Then used TimeMachine to restore the MD from backup.
From then on all my .MD files everywhere on disk suddenly scroll correctly again in QuickLook! 🙂
I suspect some caching or config that was wrong and that was reset by the procedure as an unintended but welcome side effect.
Whatever has happened behind the scenes. Now scrolling works again. Both on MD and the manually converted HTML version, which I wrote to a correct html-suffixed file after I restored the backup.
from qlmarkdown.
Sorry I oversaw one more question of you, which I want to answer, nevertheless of having closed this issue myself:
The bug is only for long documents? Can you share a .md file?
- "Longer document" as in "more than what fits into the default viewport" as in "everything that requires scrolling".
- Every .MD document which fulfilled that criteria, triggered the bug. Experienced this the last 1-3 weeks as I recall it.
Now it's gone, luckily.
Sample: This 5 paragraph lorem ipsum: Scrolling Demo.md.txt
from qlmarkdown.
Reopening
- Re-experienced the bug
- Now could better reproduce what leads to getting out of the situation:
qlmanage -r
-> Bug persists.- Restart Finder -> Scrolling works again. So what could be the cause?
- FYI
mdls myfile.md
on my system gives this Uniform Type Identifier:
…
kMDItemKind = "Markdown Document"
…
kMDItemContentTypeTree = (
"net.daringfireball.markdown",
"public.plain-text",
"public.text",
"public.data",
"public.item",
"public.content"
)
…
from qlmarkdown.
have you tried as I told you to generate the html file with the command line utility and then try to see if the preview of the html file has problems?
from qlmarkdown.
As I wrote yesterday:
I used your
qlmarkdown_cli
but unintentionally used the same file for input and output, hence overwrote the MD with the HTML. Then used TimeMachine to restore the MD from backup. From then on all my .MD files everywhere on disk suddenly scroll correctly again in QuickLook! 🙂
And now the Finder restart has also resolved the situation again.
As of now both a .MD and its .HTML counterpart gained from a qlmarkdown_cli
conversion scroll correctly.
When I get into the bug situation again, I will try a HTML conversion with qlmarkdown_cli
and see whether it differs in scrolling behavior. And only then restart Finder.
from qlmarkdown.
I hereby re-open the issue until we have more clarity on it.
from qlmarkdown.
Encountered it again:
file.md
in QuickLook in Finder had no scrolling.qlmarkdown_cli file.md -o file.html
- Now when using QuickLook in Finder the situation is: ✅
file.html
scrolls, ❌file.md
does not scroll! qlmanage -r
--> ❌ Situation unchanged to step 3.- Closing Finder window. Navigating there again --> ❌ Situation unchanged to step 3.
- Relaunching Finder. Navigating there again --> ✅
file.html
scrolls, ✅file.md
scrolls!
from qlmarkdown.
Encountered it again. Restarted macOS (instead of just Finder) --> Markdown in QuickLook scrolls normal again.
Question is, what leads to scrolling being stuck? And where/who is the proper addressee of this bug report?
from qlmarkdown.
Unfortunately I don't have a macOS 11 to test. In macos 12 a different API is used which seems to work much better. Before Monterey there are a lot of bugs in the webkit view inside a quicklook.
Try to replace the qlmarkdown app with this debug version that use the deprecated webview. Thre preview shows a "LEGACY VIEW" warning at the first line. This version cannot shows remote images.
from qlmarkdown.
Thanks for the offer.
- Though no remote image support is worse than having to relaunch Finder every here & then to get scrolling working again. So I will not use it. Unless you want me to test it actively to gain more knowhow on the bug.
- Offtopic: Sadly with my Retina MacBook Pro 15'' (Mid 2014) I'm not qualified for macOS Monterrey. Although cynically I get a notification that it's available for me, but as soon as clicked it leads me to System Preferences where it tells me I have the newest Big Sur upgrade available. Sadly again a QA screwup, which did happen very rarely in the Steve Jobs era.
from qlmarkdown.
The remote image restriction is only temporary. if the bug gets fixed I could try to implement remote image support. It seems that with the old api it is not possible to load images due to the sandbox limitations.
from qlmarkdown.
Then my pro/con balance is clear and I stick with this bug on macOS Big Sur as-is and use a Finder relaunch whenever necessary.
from qlmarkdown.
New observation
- When the Finder reaches that broken state where scrolling does not work anymore.
- Then invoking via
qlmanage -p <file>
still produces a QuickLook window with correct scrolling.- So I assume the bug cause seems to be in Finder rather than QuickLook.
- 👇 Btw meanwhile I made myself a cool QuickLook productivity feature, that I share with you 👇
Open selected text as filepath in QuickLook
- I build myself a Automator Quick Action (aka service)
- and via System Preferences → Keyboard → Services assigned it the hotkey ⌃⌥ ⌘ - SPACE.
- The currently selected text gets passed as a filepath to qlmanage.
- Whenever I read a relative filepath to a config file on a support web page, in an email, diary entry, etc, I just select the filepath text and press ⌃⌥ ⌘ - SPACE and have my QuickLook of it instantly. Great!
- This also continued to work when the Finder was in the broken state.
- Dragged the Markdown file onto TextEdit to get its filepath, then selected the filepath, and ⌃⌥ ⌘ - SPACE instantly gave me a scrolling QuickLook window.
from qlmarkdown.
Related Issues (20)
- Option to simply get raw text preview? HOT 2
- Sometimes cannot select text in quicklook window
- Math equation HOT 3
- How to speed up rendering of preview? HOT 1
- Option to disable page border HOT 3
- How can you open markdown files without the .md extension?
- Can not use Quick Look HOT 2
- Feature Request: Rendering .rst files as well? HOT 2
- Background flashes white before turning black (in dark mode) HOT 2
- Not working on Monterey HOT 5
- Cannot render escaped $ symbol when I turn on Math extension HOT 1
- The title of the exported HTML document is always `.md` HOT 3
- Although QLMarkdown.app can open the .md file, it does not appear in the "Open With" menu. HOT 3
- Remove border around page content in Finder preview/exported HTML file? HOT 1
- another UTI associated to .md files HOT 1
- Warn when modifications were made upon closing a document HOT 1
- Allow setting light/dark mode HOT 1
- Unable to disable about info. HOT 1
- Feature request: Remember QL window size and position between uses HOT 5
- The quicklook window is too big and can not remembered after resize HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qlmarkdown.