4 ms·
Am I the only one that has a problem with all non dom/html renderers that I can't copy the text on mobile? The same with flutter etc, it's such a regression in
by coolgoose 2y ago
Am I the only one that has a problem with all non dom/html renderers that I can't copy the text on mobile? The same with flutter etc, it's such a regression in my eyes but nobody prioritizes it.
- watermelon0 2y agoThere are websites that disable copying, so I assume some would consider this a feature. :/
- IshKebab 2y agoYou generally can't copy text in native UIs unless the app author goes to extra effort to allow it. It's really the web that is the odd one out here because it was originally intended for documents.
- gf000 2y agoIt also means worse accessibility, less introspection, automation, worse/impossible adblocking, etc.
- vbezhenar 2y ago> worse/impossible adblocking Obviously that's not a downside from a software developer perspective.
- robin_reala 2y agoI’m a software developer, and it seems like a positive to me? Why wouldn’t you want the ability to post-facto manipulate with script the interfaces you are presented with?
- ncruces 2y agoAs long as someone else is paying the bills.
- tcfhgj 2y agowhich ads are all about, someone else paying devs to manipulate their users into buying stuff from someone else
- vbezhenar 2y agoBecause if I added ads to my application, I want those ads to be shown to user, so I can have my money.
- robin_reala 2y agoI think this we’ve discovered the inflection point between the traditional hackers and the SV growth hackers that HN tries to court both of.
- Timwi 2y agoWhat you mean is from a capitalist perspective. Not all software developers are focused on exploiting their users.
- vbezhenar 2y agoFor applications developed by communist developers, it matters not if ads could be blocked or not. I also would argue that extensibility adds overhead to support. For example I had issue with one website where user reported that they can't see some function which clearly was there. Turned out that their adblock mistakenly removed that element because of some generic CSS class name. I'd prefer for user to receive my application in the way I planned it, not in the altered way.
- atoav 2y agoSelecting text can be useful, but it can also become its own usability problem. I recently created a touch interface using a websocket/browser based stack and one of the problem was that users kept selecting the text on buttons because they expected some action while holding the button.
- iknowstuff 2y agohttps://caniuse.com/user-select-none https://caniuse.com/user-select-none + pointer-events + touch-action : )
- laszlokorte 2y agoI currently have the same issue while building a canvas web app. Safari shows a small magnifier glass on double tap/long press and none of the css properties will suppress it.
- GranPC 2y agoI think you can work around it by listening on the touchstart event on your element and calling e.preventDefault(). Don't have an iPhone handy to test it right now, but I believe that's how I fixed that issue in my web game.
- laszlokorte 2y agoThank you for the suggestion. This is also what is discussed in some stackoverflow threads on that topic. I simply do not get why javascript is required to stop the browser from interfering with user actions. Calling preventDefault also messes with element focus and other events.
- GranPC 2y agoYeah, I am not the biggest fan of iOS Safari because of things like these. In my case, disabling most default interactions was a desirable property because I wanted to handle all the UI myself - but I understand that may not always be a good solution.
- spacechild1 2y ago> You generally can't copy text in native UIs You mean mobile apps, right? With desktop UIs this has traditionally never been an issue.
- fweimer 2y agoNever an issue in what sense? In my own experience, it's not been issue because there wasn't an expectation that this should be possible. For example, text in Tcl/Tk label widgets cannot be copied (at least not by default). There must be a way to extract text using an a11y interface, but I haven't encountered that in practice.
- IshKebab 2y agoNo, I mean with desktop UIs too. Try copying from a traditional win32 GUI or Qt or Gtk.
- rubymamis 2y agoCare to explain? All text editable widgets in Qt[1] supports text selection and copying. [1] QTextEdit, QML TextEdit etc
- dminik 2y agoThe conversation isn't about text inputs but about text labels. On the web you can usually select any text. Paragraphs? No problem. Form labels? Sure, easy. But desktop and mobile apps don't allow that. You can only select text in editable fields.
- jraph 2y agoIn dedicated widgets yes, but widgets that aren't specifically dedicated for text editing don't usually let you select the text. Try selecting explanatory text, or text associated to checkboxes in a Qt app: it won't work. There are exceptions, for example you can select text in the right side file metadata pane in the Dolphin file manager. But even this is limited: you cannot cross cells. Should you copy-paste all the metadata, you'd need to do it cell by cell.
- nicoburns 2y agoI'm currently building a GUI framework which have a flutter-like native render but that renders to DOM when targeting web. Announcement coming soon!
- adastra22 2y agoFor Rust?
- vincnetas 2y agoalso swipe to go back and cursor control with long press space is not working on ios. i would guess screen readers are also non functional for such apps
- jaimehrubiks 2y agoI'm not sure about other smartphones but for the past years I've been using a godsend feature that allows me to copy any text in any app (including text on images). It's in the app switching mode in Android (or at least Pixels), the mode where you see your opened apps after pressing home for 1 second dragging up
- disqard 2y agoThis is an amazing feature! Thank you for sharing it!!
- IshKebab 2y agoWow that is a very neat feature, thanks!
- Nullabillity 2y agoI ran into this recently in the emulator… it seems to be using a very half-baked OCR engine that can't even recognize default Android's default font correctly.
- jfhdnfbrh 2y agoAnything that is rendering to opengl/vulkan has this issue ... The issue is that there is not a good way to solve it with out hackery ... The one I saw for native android / opengl was writing to a hidden text field and selecting that with code for copy to the os clipboard...
- magnio 2y agoOn latest Android, long-pressing home activates the Google Assistant overlay, which allows you to select any text on screen (and translate and search region).
- Pesopes 2y agoYeah, but it still only uses OCR, right?
- Szpadel 2y agocorrect and it looks like it tries to do some autocorrect, not great when you need to copy some random characters password (like it was the case in the share WiFi password in previous android version, where you couldn't copy displayed password natively)
- okasaki 2y agoC-c, C-v works for me here. egui is an immediate mode GUI library written in Rust. egui runs both on the web and natively on . On the web it is compiled to WebAssembly and rendered with WebGL. Everything you see is rendered as textured triangles. There is no DOM, HTML, JS or CSS. Just Rust. egui is designed to be easy to use, portable, and fast.
- lblume 2y ago> on mobile
- Jabbles 2y agoThis is trivial to do in Flutter if the developer wants to: https://api.flutter.dev/flutter/material/SelectableText-class.html https://api.flutter.dev/flutter/material/SelectableText-clas...
- IshKebab 2y agoYes but it's not the default like it is for the web, so most text is not selectable.
- LoveMortuus 2y agoI summon Google Assistant and press the what's on my screen button, that one usually allows me to select text even when the apps don't.
- RadiozRadioz 2y agoThe layers of extreme complexity in this situation are astounding. The app has some text internally, it renders it by rasterizing fonts to a bitmap, the OS takes the bitmap and composites it within the wider UI. Google Assistant grabs a screenshot of the fully composited, post-processed OS UI, sends it over the internet to a server, which uses an OCR model to read all the text, and a different model to work out which is the relevant text, which is then sent back over the internet and displayed on the device. All so the user can copy some text.
- EddieRingle 2y agoOn Android it more or less just uses the accessibility APIs to grab the actual text, you can do it without using Google Assistant even by selecting text inside an app's thumbnail window from the Recent Apps screen.
- Nullabillity 2y agoIt doesn't. You can try running it when your keyboard is open and see what an absolute trainwreck the OCR makes of that.
- ludwigschubert 2y agoI used to be upset at such absurdities. Now I try to appreciate what a relatively universal interface images are instead! :D It doesn’t matter how text gets drawn if we OCR it. (Though I feel better when we do so on device.)
- selfmodruntime 2y agoThe crux of the issue and it's the argument I always reach for when someone on HN says HTML is the worst UI scheme we have. It's the best, being text first and equipped with a heavy focus on accessibility.
- tomjen3 2y agoThat depends. To me, if you are developing an actual app, you should not be able to select text by default - its too easy to do by accident. If you're doing editing or there's an error message, those are exceptions and of course you should be able to copy those. If what you're doing is an interactive website with texts like an article or a story, I think you should be able to copy by default, but UI elements like buttons should not have it enabled.
- 7bit 2y agoNo, you're not the only one. I really would like to understand the people that implement that, look at it and find that good. I have the impression that the vast majority of developers are idiots.
- jcelerier 2y agoConversely, whenever I have to use a web app, if I click on something and it selects the text (outside of lineedit and text areas), it just feels unfinished and unprofessional - and a big turn-off for that app in general. The worst are the ones when you can literally drag your mouse across the whole screen and it will start selecting text from entirely random places in the app's ui
- deleted 2y ago[deleted]