Code Monkey home page Code Monkey logo

jmol-swingjs's People

Contributors

bobhanson avatar charlesfoo avatar marco-foscato avatar markperri avatar onocy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

jmol-swingjs's Issues

CIF visualised in a malformed way due to the placement of the `_atom_sites_solution_primary` data item

The issue manifests at least since version 14.32.73, but no earlier than version 14.29.17.
The issue is still present in version 14.32.77.

Steps to reproduce the issue:

  1. Load the attached CIF file (test-3500015.txt) to Jmol.

Upon loading the file, the molecule is visualised in a malformed way with all of the atoms crammed together (see the image below).
3500015-malformed

However, if the line with the _atom_sites_solution_primary data item is removed, commented out or placed as the first data item, the molecule is described in a proper way (see the image below).
3500015-not-malformed

Most likely this is a CIF parsing issue since data items in a CIF file are allowed to appear in any order.

Use Jmol/JSmol on iOS

I saw on your website, your team said JSmol could be used with html5 on iOS and Android. But I don't know how to install or use it. Besides, it seems that some apps on iOS can support javascript, so can I use Jmol with these apps?

fresh checkout doesn't compile

Hi,

I'd like to try JMol, but the fresh checkout doesn't compile due to the ancient javac version settings.
After adapting the versions there are implementation errors, e.g. 'src/jspecview/application/AwtTreeNode.java'

Probably all due to a forgotten check-in, maybe.

Could you update the code?

Jmol 14.31.53 embedded in Jalview reports "viewer.getBoolean(celShading) - not listed" on stdout

Mousing over/interacting with the Jmol window generates log output that appears to come from getProperty(..) (

Logger.error("viewer.getBoolean(" + T.nameOf(tok) + ") - not listed");
)

Not sure what's going on here ! Help ?

Jalview issue lodged at: https://issues.jalview.org/browse/JAL-3874
Java version: 11.0.11
x86_64 Mac OS X 11.5
LookAndFeel: VAqua (org.violetlib.aqua.AquaLookAndFeel)

customize colors for structure

Hello,

I download the latest verstion of Jmol and extract JSmol from sourceforge.

Not sure whether I should use library from sourceforge or use this Jmol-SwingJS library.

Currently I use the sourceforge one and want to customize colors for a structure.

I wrote the following code, but the customization does not work, it still displays the default color setup.

			Jmol.script(jsmolApplet, "wireframe off; spacefill off; ");
			Jmol.script(jsmolApplet, "cartoon on");
			Jmol.script(jsmolApplet, "color cartoon structure");
			Jmol.script(jsmolApplet, "spin on");
			Jmol.script(jsmolApplet, "select all; color cartoon [FFFFFF]");
			Jmol.script(
				jsmolApplet,
				"select protein and helix; color cartoon [FFA500]"
			);
			Jmol.script(
				jsmolApplet,
				"select protein and sheet; color cartoon [FFFF00]"
			);
			Jmol.script(
				jsmolApplet,
				"select not helix and not sheet; color cartoon [0000FF]"
			);

I am not sure whether I am using the correct library.

Do you have any idea about that?

Thank you!

WebExport broken sometime after 14.30.2

WebExport after 14.30.2 does not write the .html file or any script or data files when building a page. This probably relates to changes to the filewriter operation in WebPanel.java beginning at about line 614:

        Lst<String> filesToCopyUTF = (Lst<String>) new ArrayList<String>();
        FileManager.getFileReferences(script, filesToCopy, filesToCopyUTF);
        ArrayList<String> copiedFileNames = new  ArrayList<String>();
        int nFiles = filesToCopy.size();
        for (int iFile = 0; iFile < nFiles; iFile++) {
          String name = filesToCopyUTF.get(iFile);
          int pt = name.indexOf("::");
          String type = "";
          if (pt >= 0) {
            type = name.substring(0, pt + 2);
            name = name.substring(pt + 2);

J. Gutow is looking into this, but any information about why and in which commits these changes were made would be helpful.

unwanted chirality in -SO3H groups

Jmol (14.32.39) possibly assigns sulfonic acids as chiral.

Related to an earlier post here, I observe Jmol assigns chirality for -SO3H when issuing the command

 print {thisModel}.find("SMILES");

though the displayed bond order suggests two S=O, i.e. two out of four substitutents as equal. Their bond length is pretty much similar (1.45 A), while the S-O are distinctly longer (1.61 A):

2022-03-22_Jmol_SO3H_chirality

To ease the comparison, the .sdf in question is attached below.

2022-03-22_examples_SO3H.sdf.zip

Update UI

I hope I could help but please do update the UI so to be more interactive... :) Thanks!!!

Local files fail to load via the menu bar

The issue manifests at least since version 14.32.79.
The issue was not present in version 14.32.77.

I noticed the issue while using the Jmol version downloaded from SourceForge full-tar.gz [1]. I have not tried compiling the source code, but I am willing to do so if you cannot reproduce the issue. Tested on LinuxMint 21 with openjdk version "11.0.16" 2022-07-19.

Steps to reproduce the issue:

  1. Download and extract the tar.gz file.
  2. Go to the jmol-14.32.79-full/jmol-14.32.79 directory.
  3. Run the "../jmol" script (script resides in the parent directory of the current working directory).
  4. In the menu bar click File -> Open and select the file to open.

The selected file fails to load properly (no atoms appear) and the program itself seems to get stuck in a strange state, i.e. the "Get PDB" options fails to open, right clicking the view window opens a menu with the molecule editing functionality instead of the expected regular one, etc. Tested by trying to load CIF and SDF files that work perfectly fine on earlier versions.

What is more, loading files in an alternative way do not produce the same issues. For example, a freshly started program can properly load the same file by right clicking the view window and selecting File->Load->Open local file options.

Please let me know if you can reproduce the issue and if you need any additional information.

[1] https://sourceforge.net/projects/jmol/files/Jmol/Version%2014.32/Jmol%2014.32.79/

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.