Skip to content
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

Open .txt files optionally with external editor #108

Closed
SailReal opened this issue Mar 8, 2018 · 8 comments
Closed

Open .txt files optionally with external editor #108

SailReal opened this issue Mar 8, 2018 · 8 comments
Labels
state:has-workaround There is a known workaround for the described problem type:feature-request New feature or request
Milestone

Comments

@SailReal
Copy link
Member

SailReal commented Mar 8, 2018

At the moment, all files of type txt will be openened with an build-in editor. It could be useful to choose to open txt-files with the build-in- or an external editor.

Workaround
Text files in fact can be opened in an external editor by using the share functionality.

@SailReal SailReal added the type:feature-request New feature or request label Mar 8, 2018
@SailReal SailReal added this to the Backlog milestone Mar 8, 2018
@markuskreusch markuskreusch added the state:has-workaround There is a known workaround for the described problem label Mar 16, 2018
@markuskreusch
Copy link
Contributor

markuskreusch commented Mar 16, 2018

There were some remarks in App Store comments stating that this would create non encrypted copies of the files on the phone. Some clarification regarding this:

  • From a technical standpoint "sharing" equals showing a file in an external app, so there is no real difference.
  • To show a file in an external app Cryptomator MUST allow the app to read the decrypted data. This data is placed on the device in a way that only allows access by the specific app selected by the user. No other app will have acess to this data.
  • After sharing control over the decrypted data is transferred to the used app. If this app creates a decrypted copy somewhere Cryptomator can neither influence nor be responsible for this. If only trusted apps are installed on a device this should be ok.

Maybe we should rethink the sharing behaviour. It may not be obvious to most users that, when tapping on a file like a pdf an external app (the default pdf viewer) opens. Maybe we should just show file details on tap and allow opening a file externally only in a more explicit way. Such a file details view could be switched to our internal text editor or the image preview for applicable files.

@Jer73
Copy link

Jer73 commented Mar 22, 2018

Unfortunately the sharing does not lead to a workable solution for a text file. Tried two text editors (ES Note Editor and Firefox, which I used previously with Boxcryptor classic), but both don't open the text file.

Can the user not just choose which app to open the file with (default Android behaviour). Example of preference in obsolete Boxcryptor classic, which - upon unselecting, would get the Android selection menu which app to use:
2018-03-22 21 18 32-3

@markuskreusch
Copy link
Contributor

When sharing we build an ACTION_SEND intent. The EXTRA_STREAM is set to the content URI of the shared file and the flag FLAG_GRANT_READ_URI_PERMISSION is set so the receiving app can read the URI. If the file has an extension the type is set to the MIME type returned by MimeTypeMap for this extension. We then use Intent.createChooser to trigger the default android app choosing behaviour.

If you do not see a chooser your system may allow you to define an app as default. In this case the chooser may be skipped. You should be able to reset this in the Android settings.

Do the apps you are using display some kind of error message? If so we may have a closer look at this but as the intents we use are really much standard there may not be much we can do. Otherwise I would recommend you contact the vendor of the apps for help.

@Jer73
Copy link

Jer73 commented Mar 23, 2018

Thanks for your reply.
What happens on my Samsung Galaxy S7, using the share functionality:

  • ES Note Editor: "Could not read file /decrypted/test.txt"
  • Firefox: "No link found in this share"
    I also get options to share to e.g. whatsapp, gmail: quite different from selecting a normal txt file (see below).

Testing with another text file outside Cryptomator brings up the Android app chooser with 5 text editors, as expected. My feeling is that the share functionality is quite different from the "open with" as I would have liked.

@Jer73
Copy link

Jer73 commented Apr 22, 2018

How do we get this moving? Without the option to open .txt files with an editor capable of searching through the text file, Cryptomator is not a workable solution for me. What can I do to support?

@zoo1ook
Copy link

zoo1ook commented May 23, 2018

Moved from BoxCryptor Classic and really miss the ability to choose my preferrede editor.
Alternatively, build in search facility and Unicode support in the inbuilt editor.

@martinhws
Copy link

With my Samsung Galaxy Note 9 and QuickEdit (defined as standard app for .txt) the app opens but shows no content.

Are there any news how to use a search facility in .txt-files, either in the inbuilt editor or via external editor?

@AndresRohr
Copy link

Yeah, I would like to use the great Jota Text Editor. Has everything the heart desires. Come on guys, I would program somthing like that in 10 Minutes on Windows. Can't anybody do such an easy to implement thing? I would really like to use Cryptomator but I have really big text files with my notes in it. I need a sophisticated editor, not a toy. Thanks in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
state:has-workaround There is a known workaround for the described problem type:feature-request New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants