-
-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mobile support does not seem to work #52
Comments
I don't have an Android device so I can't easily debug this.
|
I see. The fact that the conceal and color matching brackets features are working means that the plugin is loading correctly, and CodeMirror extensions are working.
|
Hmm I see. Do you get any errors when you first enable the Latex Suite plugin? It does seem strange that you get no errors. Please give me some time to put together a debug build and get back to you! |
Sorry for the late reply. It sure was strange but I just double checked it, and I really didn't saw any errors after I enabled the Latex suite plug-in. |
@eliazar-sll Have you noticed the underline on what you typed? I think this is a problem about your input method . When you are typing , the input method actually hold the letters without passing it to obsidian . Only after you select a word or press something like |
Ah, It's a bit strange. I tried it by myself, and find almost all input methods on android won't work with latex suite... However, trime does work for me. I have no clue about why they work or not work though. Maybe something about input key event? |
I've put together this debug build. It prints some console.log statements whenever the plugin detects a keypress. obsidian-latex-suite-1.6.0-debug.zip Can any android users test this build and upload a video of what appears in the console? It would be helpful if you did this using the different keyboards that do/do not work, described by @proItheus above. |
Sorry but how can I enable the |
@proItheus Quoting from @artisticat1, I think this is the process of enabling
|
@artisticat1, I just tried the debug build and it logs |
Confirmed that the plugin logs keydown normally for the |
Thank you both! It appears that keypresses are not being transferred to the plugin correctly. I'll try to investigate this further. |
Can you visit https://codemirror.net/try/ and paste the following code into the editor on the left hand side? import {minimalSetup, EditorView} from "codemirror"
import {Prec} from "@codemirror/state";
const onKeydownExtension = Prec.highest(EditorView.domEventHandlers({
"keydown": (event, view) => {
console.log("The " + event.key + " key was pressed.");
}
}));
new EditorView({
doc: "...",
extensions: [minimalSetup, onKeydownExtension],
parent: document.body
}) (Erase the code contained in the editor by default.) This code will set up a test editor with a debug statement that prints out keypresses the editor detects. Press the "Run" button after pasting in the code in order to initialise the test editor (which sits on the right hand side). Then, in the editor on the right, type in some text. Then switch to the "Log" tab and let me know what it says. |
LaTex suite seems to work in android with an external keyboard. Yet it doesn't work at all in other circumstances. |
Hi @artisticat1, has there been any further investigation about this? |
I think it's some sort of issue with CodeMirror not receiving key-press events from Android keyboards. I don't think there's much I can do on my side, except possibly look for a workaround. |
Hi @Deadbush225 ,I found a solution. Specific methods are as follows:
(This solution will be better if someone found a common keyboard without IME) |
Has anybody found a workaround to this? |
@pikatwinky it is kinda working for me. I'm using codeboard. I believe the problem was partly solved when obsidian migrated to codemirror6 but I'm wildly guessing. edit: actually, it reports correctly now as |
@oldkingOK have you tried using codeboard keyboard? It almost works perfectly but I haven't had any luck with autofractions for example. Codemirror seems to correctly identify the keypresses like / and Tab key despite it not working (I tried it in codemirror.net/try). |
latex suite is a great plugin, but unfortunately it doesn't work on mobile. Are you considering adding mobile support when using IME input methods such as Gboard. Thank you very much. @artisticat1 |
@TomBPotochek Sorry for the late reply. I just try it. It's quite strange that the physical keyboard works well with autofractions while the codeboard doesn't work. The reason might be the symbol "/" on the codeboard can be customized, which probably means that only symbols on codeboard use IME. |
@TomBPotochek Finished, Edit: This repository was accidentally deleted by me, you can find the download link in the comments below. |
@oldkingOK great, it's working! I see it was a fairly simple change. I would not have known. Now this just needs to be done for the other symbols and the problem is solved completely (eg. One small thing I've noticed is that now the |
@TomBPotochek you're a lifesaver, thanks for the suggestion about using codeboard. @oldkingOK Thank you so much for sharing that build of the app It's such a shame that that keyboard doesn´t recieve support anymore, i hope it doesn't break very soon. |
It should be possible to handle IME input - for reference, here's how the vim CM6 plugin handles it. Any PRs for this would be welcome. |
Sorry for my improper description. The "word mode" is a function that the keyboard can give word suggestions after every key input like the screenshot below. |
@oldkingOK ,Yes,It works, but the 'tab' key is does't work when using the external keyboard. |
@henusys , the 'tab' key work fine with my external keyboard.
|
Android version is MIUI 12.5.2, If I use the codeboard input method, everything works well. But when using sougou input, '\alpha' '\beta' '\frac' and so on could be triggered well, while for the triggered '\frac{}{}' the tab key just reponse the tab and isn't move the cursor to the next brace. |
@henusys ,It works well with my devices,
If it still doesn't work, I will appreciate it if you could help me debug through the way above.
|
Yes I test it just now. once I type 'mk' or 'dm' to trigger the math mode, the error console will appear similar message as follows:
and
But if I quit the current edite, and then directly select to edit the mathematical formula by touch screen, not use 'mk' to trigger math mode, the error message will not appear and tab key also working well. |
@henusys Thats a little strange, is there any messages like
after tab key pressed? |
@henusys ,So, it means that the latest Sogou keyboard will cause problems while the sogou keyboard custemized for MIUI works fine?
Yes, I have noticed that and plan to figure it out after solving other main issues. |
Yes you are right, thank you very much. |
You're welcome. And thanks for your testing. |
Okay apparently the "bug" on the Samsung Keyboard I've shown above happens when make.md plugin is enabled. This bug only happen on mobile. Obsidian on my PC doesn't have this problem at all. |
HI @IEatCodeDaily, I cannot seem to get LaTeX suite working with a similar arrangements - I am on One UI 5.1 on a Z Fold 4 using stock samsung keyboard. Could you share your settings for the samsung keyboard? Thanks! |
Ah sorry, I forgot to mention that I'm using the physical keyboard. Without the physical keyboard I'm also unable to get LaTeX suite working no matter what. |
I have also just started getting this issue. It used to work fine on my Samsung galaxy tab s8. However it stopped working recently (i believe after i updated the os). Not sure if this helps but it works as a temporary solution. |
这个链接失效了,请问现在还有解决方法吗 |
@JavenQvQ Here is the file, its the same he uploaded. It seems he just deleted his repo |
I have a TCL NEXTPaper 14 Android tablet. After much time, experimentation, and frustration, I finally managed to activate my snippets from an external keyboard using the Android app Unexpected Keyboard. The Hacker's Keyboard, which I use on my Motorola phone (Android 12), did not work! Additionally, I encountered the issue that Google does not provide an option to uninstall or deactivate the Gboard keyboard on Android 14. Unexpectedly, the app Keyboard Switcher allowed me to do deactivate it! As a result, the plugin now works just fine with an external keyboard. However, the snippets still cannot be expanded using the virtual keyboard. |
I have been using Latex-Suite for more than a year now and it helps a lot, thanks a lot to all the maintainers of this repo. I've updated the previous code and after testing with my device, the following keyboards have been supported nicely, including virtual and external keyboards, and there is no need to turn off the word completion.
You can try the plugin I compiled at Releases/1.9.7-dev, I would like to get feedback from you guys on testing it :) Important: You need to turn off |
Hi @johnsidi77 , I only have two android device and my code still needs more testing, can you try it? I'd appreciate it. |
Sad, I can't write math using this plugin on my chromebook even if I use a physical keyboard :( Hoping for someone to fix this, thanks. |
The support for mobile (android) doesn't seem to work.
I tried it on both of my android devices but neither of them worked. I checked if other plug-ins caused that, so I made a fresh obsidian installation but it still has no effect.
Additional Details:
The text was updated successfully, but these errors were encountered: