Difference between revisions of "Support/Android"

From Jmol
Jump to navigation Jump to search
m (Reverted edits by Lanita1223 (talk) to last revision by AngelHerraez)
(JSmol pages offline in Android)
 
(3 intermediate revisions by 2 users not shown)
Line 26: Line 26:
  
 
== JSmol ==
 
== JSmol ==
Jmol may be run in systems that do not support Java by using the HTML5 '''JSmol''' format included in [[Jmol JavaScript Object]] (version 13.1 and later).
+
 
 +
=== Online ===
 +
'''Any and all''' web pages designed using JSmol in the HTML5 modality will work in Android-based systems, '''via the web browser''' (i.e., this is not an app and in general requires a live internet connection). The user experience with the molecular models may however be hindered by
 +
* the screen size design of the page,
 +
* support for tactile systems of the page interface and source code,
 +
* processor power of the device (will affect responsiveness of the JSmol object in the page, i.e. smoothness of rotation),
 +
* download time of the page + JSmol library files,
 +
* need for a live internet connection
 +
 
 +
More responsive, mobile-friendly pages may be written using the [[Lightweight JSmol]] object. Note that this is limited to {{file|mol}}-formatted molecular files and to the basic ball-and-stick rendering.
 +
 
 +
=== Offline ===
 +
JSmol-containing web pages will not run in the web browser when the files are local in the system, i.e., not coming from a web server. This is seemingly due to the way the web browser interacts with the Android file system and an inability to link to local files that specify the JavaScript code used by JSmol.
 +
 
 +
One solution is to install a localhost web server. An example of a free app that allows to do this is "HTTP Server powered by Apache". When you install it, make a note of the location of the home folder (something like {{folder|htdocs}} in the internal memory storage) and of the url address used by the server (like <code><nowiki>http://0.0.0.0:8000</nowiki></code>).
 +
Put your files somewhere inside the {{folder|public}} subfolder of the home folder, launch the server app and navigate to the home url and then the subfolder that contains your pages.
  
 
== Wallpaper ==
 
== Wallpaper ==
 
Dominik Raymann has written a wallpaper for Android devices that uses Jmol to display rotating molecules. You can choose a single favorite one or have it random, as well as whether to display the name of the molecule.
 
Dominik Raymann has written a wallpaper for Android devices that uses Jmol to display rotating molecules. You can choose a single favorite one or have it random, as well as whether to display the name of the molecule.
 
Read more at the [https://market.android.com/details?id=ch.raymi.android.molecules Android Market] page.
 
Read more at the [https://market.android.com/details?id=ch.raymi.android.molecules Android Market] page.

Latest revision as of 16:20, 15 September 2018

Jmol under Android Operating System (smartphones and tablets)

Jmol Android App

Jmol 12.3 is available in a special version for running in tablets under the Android operating system: Jmol Molecular Visualization Activity, version 1.1, requires Android 2.2 or later. Available for free.

Information and download from the Android Market.

  • A nearly full touch-screen implementation of Jmol.
  • Includes a variety of preset simple visualization modes.
  • Allows for command-line entry of Jmol commands.
  • Includes a full range of visualizations for crystals (unit cells, symmetry operators, Miller planes, for example).
  • Includes a wide variety of surfaces including Van der Waals surfaces, solvent-accessible surfaces, cavities, and molecular surfaces, and atomic and molecular orbitals.
  • Directly accesses the Protein Data Bank (PDB, with over 60 000 biomolecular structures) by keyword or by PDB ID.
  • Directly accesses the National Institutes of Health National Cancer Institute (NIH/NCI, with over 40 million structures) using a wide variety of chemical identifiers, including CAS registry numbers, InChI keys, trade names, common names, and IUPAC-format names.
  • Files from any other internet-available site that can be read by Jmol may also be loaded.
  • Connects to the gyroscope, allowing for initiating of spinning by simply moving the tablet in a natural fashion (see Videos).

This activity is under development. Feedback is much appreciated.

A collection of notes about present or possible support for Jmol under Android:

  • Since Android doesn't include the Swing Java class, the pop-up menu, the console and the prompt command used for asking for saving files from the signed applet will not work. But other functionality may work.

JSmol

Online

Any and all web pages designed using JSmol in the HTML5 modality will work in Android-based systems, via the web browser (i.e., this is not an app and in general requires a live internet connection). The user experience with the molecular models may however be hindered by

  • the screen size design of the page,
  • support for tactile systems of the page interface and source code,
  • processor power of the device (will affect responsiveness of the JSmol object in the page, i.e. smoothness of rotation),
  • download time of the page + JSmol library files,
  • need for a live internet connection

More responsive, mobile-friendly pages may be written using the Lightweight JSmol object. Note that this is limited to File icon.gifmol-formatted molecular files and to the basic ball-and-stick rendering.

Offline

JSmol-containing web pages will not run in the web browser when the files are local in the system, i.e., not coming from a web server. This is seemingly due to the way the web browser interacts with the Android file system and an inability to link to local files that specify the JavaScript code used by JSmol.

One solution is to install a localhost web server. An example of a free app that allows to do this is "HTTP Server powered by Apache". When you install it, make a note of the location of the home folder (something like Folder icon.gifhtdocs in the internal memory storage) and of the url address used by the server (like http://0.0.0.0:8000). Put your files somewhere inside the Folder icon.gifpublic subfolder of the home folder, launch the server app and navigate to the home url and then the subfolder that contains your pages.

Wallpaper

Dominik Raymann has written a wallpaper for Android devices that uses Jmol to display rotating molecules. You can choose a single favorite one or have it random, as well as whether to display the name of the molecule. Read more at the Android Market page.