38 Commits

Author SHA1 Message Date
Jarrett Johnson
9742359bc0 Replace OV (AtomInfo) 2021-07-07 12:19:24 -04:00
Thomas Holder
1142e3ab22 PYMOL-3570 Bonds to crystal symmetry mates 2021-02-11 18:58:26 +01:00
Thomas Holder
27385b023d Remove unneeded BondType members
BondType::id
- was imported from MOL2 and ChemPy PKL
- was exported to ChemPy PKL
- had no API for querying or manipulation, other than IO with SDF/PKL

BondType::stereo
- was imported+exported from+to SDF and ChemPy PKL
- had no API for querying or manipulation, other than IO with SDF/PKL
- is a 2D projection property (but PyMOL doesn't do any 2D projection)

BondType::temp1
- Used in various places. Usage refactored to use local data structures.

Remove unused functions (leftovers from old undo system):
- BondTypeCompare
- AtomInfoCompareAll
2020-12-03 18:13:22 +01:00
Thomas Holder
60bafcace1 Remove _PYMOL_NO_UNDO stubs 2020-06-22 11:07:06 +02:00
Thomas Holder
3de28cdc2c PYMOL-3236 Improve handling of "pseudo" atoms 2020-02-20 12:08:32 +01:00
Thomas Holder
4add76a733 fix PYMOL-3348 zoom on case-sensitive objects 2020-01-22 11:52:24 +01:00
Thomas Holder
4f50d7568a eliminate pymol::vla non-const legacy VLA cast
Avoid assignment of pymol::vla<T> return values to T*.

Refactoring to facilitate this:
- const-correctness (const T* cast still works)
- .data()
- T* -> pymol::vla<T> function arguments
2019-09-23 15:56:55 +02:00
Thomas Holder
55135c8d04 pymol::zstring_view 2019-06-07 16:22:08 +02:00
Thomas Holder
bae446f0b9 PYMOL-3227 fuse: consider atoms w/o coordinates 2019-04-23 16:31:43 +02:00
Thomas Holder
b59ce09d8a refactor: pymol::malloc<T>
- use typed/namespaced malloc wrapper
- remove Alloc et al.
- remove mmalloc et al.
- remove CINTERFACE define
2019-02-21 17:41:58 +01:00
Thomas Holder
0fc3845e5a PYMOL-3193 doxygen-style comments 2019-01-29 20:48:11 +01:00
Thomas Holder
1eab612a45 refactor: lexidx_t -> const lexidx_t&
pave the way for a non-primitive lexidx_t
2018-11-15 16:09:44 +01:00
Thomas Holder
665aa6884a fix wildcard, fix PDB 99999 crash, PQR parsing...
* fix selection wildcard (sf.net/p/pymol/bugs/209)
* fix PDB atom id > 99999 crash
* more robust PQR parsing
* pymol2.PyMOL() context manager
* new setting: cif_metalc_as_zero_order_bonds
* new setting sdf_write_zero_order_bonds
* cif: accept _chem_comp_bond.type alias for _chem_comp_bond.value_order
* better support for mingwpy compiler (Christoph Gohlke)
2018-06-08 10:52:36 +00:00
Thomas Holder
1742d75d13 anaglyph batch mode, all_states measurements, ...
* fix anaglyph stereo in batch (headless) mode
* fix possible memory corruption with boolean settings
* measurement wizard: distances between states (all_states=on)
* get_fastastr: nucleic acid, by chain
* menu: A (Action) > group
* sequence viewer menu: ss (Secondary Structure)
* MAE export of groups (s_m_subgroupid)
* macOS: -O3 -fno-strict-aliasing (bugs/205)
2018-05-03 14:46:44 +00:00
Thomas Holder
4bbe42513c stick_round_nub, UTF-8, display_scale_factor, ...
* stick_round_nub for COLLADA export
* UTF-8 in feedback
* display_scale_factor (ported from Incentive PyMOL)
* dx map import: support "type float" and skewed delta
2018-02-28 13:16:16 +00:00
Thomas Holder
e2df29a2ee polymer.protein polymer.nucleic multifilesave ...
* new selection keywords: polymer.protein polymer.nucleic
* new command: multifilesave
* MMTF export (requires simplemmtf python module)
* select: present, state -1 -> current object state
* create: source_state = -1 -> current
  (was: source_state = -1/0 -> all)
* cif: support quoted '?' and '.' as values
  cif_get_array -> None instead of empty string for ? and .
* fix copy discrete object w/o coords
* fix loading pdbqr AutoDock 4 atom types
* fix get_model('none') and get_str('mol', 'none')
* h_add refactored: 5x faster, support discrete objects
2018-02-07 15:44:17 +00:00
Thomas Holder
5acb6c4637 py37, align alt, flag 6+7
* Python 3.7 support (https://sf.net/p/pymol/bugs/197/)
* enable align with alt-codes
  - allow matching of non-alt-code to alt-code atoms in alignments
  - swap sorting priority of 'name' and 'alt' identifiers
  - sort empty 'alt' before non-empty 'alt'
* flags 6 and 7 for protein and nucleic acid
* mmCIF: read _atom_site.pdbx_formal_charge
* improve coordinate loading from mmcif chem_comp files
  - ignore columns with all ? (missing) values
  - select columns with "chem_comp_cartn_use" setting
* fix h_add: skip missing coordinates
2017-12-21 12:50:47 +00:00
Thomas Holder
3c78ffc986 pymol/bugs/196, pmw/bugs/47
* fix elements from .gro files (pymol/bugs/196, r4181 regression)
* save .mtl: raise exception
* Python 3:
  - fix "GUI Font Size" dialog (pmw/bugs/47)
  - fix COLLADA export
2017-11-15 14:40:53 +00:00
Thomas Holder
2a2a0579a1 some elements wrong from SDF and XYZ
Reported by Xin Wu: "Si" element from XYZ file loaded as "S"
2017-10-26 09:15:39 +00:00
Thomas Holder
2fca882cf7 1.8.6.1 fixes
* Python 3: fix builder bond order buttons (Red Hat Bug 1442127)
* fix MAE export PDB residue/atom names
* restored "scene_animation" setting (1.7.6 regression)
* restored "import cmd" prevention (1.8.6.0 regression)
2017-04-17 18:13:26 +00:00
Thomas Holder
999ceebbe8 1.8.3.2
* experimental MMTF load support
* map export in CCP4 format
* SDF V3000 import/export support
* refactor molecular file formats export: Unified handling of PDB, PQR, mmCIF, MOL2, SDF, XYZ, MAE
* PLY geometry import (as CGO)
* new command: unset_deep
* new setting: cartoon_all_alt: Create cartoon for every alt code
* stick_h_scale: default=1.0 (was: 0.4) but remove dependency on negative stick_radius
* auto_show_classified: Visualize small (< 50 atoms) polymer classified molecules like organic
* bymol selection operator: ignore zero-order bonds
* menu: isomesh/surface negative color
* improve alignment of residues with unknown resn (e.g. ligands):
  give a match score of 5 to perfect matches of unknown residue codes.
  Previously, those got match score -1.
* remove broken and obsolete "PMO" file support
* use "label_digits" setting with "label" command
* do not resize window when loading a session file
* fix ignored SCALE w/ identity rotation (e.g. 1WAP)
* fix "scene auto, clear" (Scene > Delete)
* new setting: pick_shading: do flat shading for programmable image color analysis
* experimental cmd.raw_image_callback: post cmd.draw() callback
2016-08-30 19:14:39 +00:00
Thomas Holder
27252080d6 fix mutagenesis wizard, FreeBSD support
- fix mutagenesis wizard "No Mutation" (update and rms commands)
- experimental FreeBSD support
2016-05-26 22:18:53 +00:00
Thomas Holder
b3472cbace ignore_case_chain, cartoon_gap_cutoff, ...
* restore ignore_case=on default
* new setting: ignore_case_chain (default off)
* new setting: cartoon_gap_cutoff
* increase PYMOL_MAX_THREADS
* amber topology loading: bond order 1 for all bonds
* improve MOL2 file handling
* new grid_mode=3: grid per object-state
2016-02-08 15:59:56 +00:00
Thomas Holder
2787af79fc byring, distance mode=4, cartoon dash, ...
* distance mode=4: distance between centroids
* byring: new selection operator
* "Distances to Rings" mode in measurement wizard
* basic atom typing for MOL2 export
* cartoon dash: new dashed loop-like cartoon type
* object-level settings for measurements
* iterate: use Python exceptions
* iterate_state: ignore atomic=0 (fixes crash)
* format 'xyzstr': enable .gz and URL loading
* fix crash with object sele length >= 1024
* re-add -Wno-write-strings
* fix pmg_tk.skins.normal.encode()
* fix askopenfilename CANCEL case with multiple=0
2016-01-11 16:56:37 +00:00
Thomas Holder
9f53f30e47 segi, resn, name of arbitrary length; settings in iterate/alter
* support segi, resn and name of arbitrary string length
* expose settings to iterate/alter via "s.<name>"
* Python 3 compatibility for champ module
* apbs_tools: apply fixes from Pymol-script-repo
2015-12-14 19:11:12 +00:00
Thomas Holder
b3671875f1 backport to pre-c++11 for OS X <= 10.8 2015-11-12 00:10:37 +00:00
Thomas Holder
a9b686ad77 color autocomplete for ramps, improve volume blending 2015-10-29 12:10:08 +00:00
Thomas Holder
f9f76fed07 scene_buttons=on, ...
* new default: scene_buttons=on
* normalize_ccp4_maps=2 -> use mean and stdev from file header
* fix alignment with atoms w/o coords in a state
2015-10-15 17:43:51 +00:00
Thomas Holder
92179cf33f pdbml, pdbqt, cml, get_object_ttt, ...
* new filetypes: pdbml, pdbqt, cml
* cell/symmetry: accept alpha=beta=gamma=0.0 as 90.0
* leave unknown protons as -1 instead of 0 (lonepair), fixes vdw assingment for unknown elements (1.8 instead of 0.5)
* reimplement reading full sequence from mmCIF. Only with cif_use_auth=off and retain_order=off. Fill in missing CA atoms for polypeptides.
* new API function cmd.get_object_ttt()
* APBS Plugin: --whitespace argument for pdb2pqr
* fix scene next/previous, was broken on Windows 10
* fix split_states with non-unique titles
* fix "File > Run" fails if path has spaces
2015-10-06 18:15:01 +00:00
Thomas Holder
680f313001 cartoon_trace_atoms for sheets, fast connect_mode=4 2015-08-31 02:08:17 +00:00
Thomas Holder
13abb9fa2e fix building on CentOS 6.3 / python2.6 / gcc 4.4.7 2015-08-13 11:23:04 +00:00
Thomas Holder
7452ac469b 1.7.7.2
* cif_keepinmemory, pymol.querying.cif_get_array (experimental)
* ramp_update (new command)
* ramp objects now have "A > Range > ..." and "C > ..." menus
* mmCIF _chem_comp_atom: skip atoms with missing coordinates, prefer ideal over model coordinates
* cmd.set_key() decorator support
2015-08-12 16:45:05 +00:00
Thomas Holder
8bf29abf88 post sf.net downtime update
* fix isosurface all_states rendering
* pdb_hetatm_guess_valences for CIF loading
* mutagenesis wizard: improve "apply" performance
* fix measurement and alignment object partial PSE loading
* some load/save refactoring
* keep atom IDs when creating object from selection
* when renaming group "A" to "B", then also rename entry "A.X" to "B.X"
2015-07-29 14:25:52 +00:00
Thomas Holder
dad194ad0f Restore scenes "disable" recall behavior...
- scenes: Restore the old behavior that when recalling a scene, all objects
  which were not present when storing the scene are disabled.
- fix auto-complete for filenames with spaces
- fix an object menu panel group ordering problem

Refactoring:
- remove unused variables (Partly applies https://sourceforge.net/p/pymol/bugs/166/)
- lots of: char* -> const char*
- remove inline Parse functions, simplify ParseFloat3List
- make functions static
2015-04-09 21:35:38 +00:00
Thomas Holder
22fdfe3e81 fixed roving detail/density demos, removed unused code
* fixed roving density and roving detail demos (regression from last commit)
  http://sourceforge.net/p/pymol/bugs/156
* fix "narrowing conversion" C++ errors
* removed unused code and preprocessors:
  _PYMOL_GL_DRAWARRAYS
  _PYMOL_GL_CALLLISTS
  _PYMOL_CGO_DRAWARRAYS
  _PYMOL_CGO_DRAWBUFFERS
  OPENGL_ES_1 
  OPENGL_ES_2
* removed deprecated "register" specifier
2015-03-13 22:19:47 +00:00
Thomas Holder
9bb5c2d971 1.7.5.0 (unstable/experimental)
* mmCIF _atom_sites.fract_transf support (SCALEn equivalent)
* Complete port of scenes to C++
* warn user if setting a setting on the wrong level
* cmd.extendaa: shortcut for cmd.extend with argument auto-completion
* reduced memory footprint of AtomInfoType
* expose "reps" to iterate/alter
* expose "protons" to iterate/alter
* adaptive cartoon quality and sampling, depending on number of atoms
* fix ring center color with cartoon_ring_color=default
* make SelectorGetTmp strictly molecular, fixes for example "dss" with group names
* fix "copy" can cause crash
* fix "custom" selection operator
* consider spec_count in shaders
* don't invalidate shaders for lighting settings
* don't disable shaders for all Intel chips
* don't touch sphere_mode when disabling shaders
* map_new buffer == -1 -> gaussian_resolution
* fix all_states picking
* remove cylinder_shader_ff_workaround and cylinders_shader_filter_faces
* remove unused gl_ambient setting
* fix Tcl/Tk menu settings logging
* fix: grid mode scales down label size incorrectly
* fix: no animate argument for cmd.origin
* fix side_chain_helper for hetatm polymer atoms
* fix .mmd export
* refactor many function to take "const" pointer arguments
2015-03-12 17:44:19 +00:00
Thomas Holder
e274a46085 fast CIF loading, 1.7.3.1 (unstable/experimental)
* fast PDBx/mmCIF and core CIF loading in C++
* new connect_mode=4 does bonding with components.cif dictionary
  (mmCIF only, components.cif needs to be present in current
  directory)
* gray out residues in the sequence viewer that are missing from the
  current state; Read missing residues from mmCIF files
  (_pdbx_unobs_or_zero_occ_residues records) so that they show up in
  the sequence viewer
* add spider map reading support
* load "map" as ccp4 instead of throwing "ambiguous" error
* xyz write support
* Improve right-button zoom: use origin instead of clipping slab
  center as depth indicator, fixes zoom speed when far clipping plane
  is very far away
* don't use dynamic_width for nonbonded rep
2014-10-16 20:14:27 +00:00
Thomas Holder
f42840260b c++ for all PyMOL c files
- renaming files c -> cpp
- c++ specific syntax (::)
2014-09-08 13:42:11 +00:00