Table of Contents

Class: bond bkchem/bond.py

class BOND--------------------------------------------------

Base Classes   
meta_enabled
line_colored
drawable
with_line
interactive
child_with_paper
oasa.bond
Methods   
__init__
_compute_sign_and_center
_decide_distance_and_center
_draw_a1
_draw_a2
_draw_a3
_draw_adder
_draw_b1
_draw_b2
_draw_b3
_draw_d1
_draw_d2
_draw_d3
_draw_dash
_draw_h1
_draw_h2
_draw_h3
_draw_hatch
_draw_n1
_draw_n2
_draw_n3
_draw_second_line
_draw_w1
_draw_w2
_draw_w3
_draw_wedge
_get_atom1
_get_atom2
_get_atoms
_get_auto_bond_sign
_get_bond_width
_get_center
_get_dirty
_get_double_length_ratio
_get_molecule
_get_order
_get_parent
_get_simple_double
_get_type
_get_wedge_width
_set_atom1
_set_atom2
_set_atoms
_set_auto_bond_sign
_set_bond_width
_set_center
_set_dirty
_set_double_length_ratio
_set_molecule
_set_order
_set_parent
_set_simple_double
_set_type
_set_wedge_width
_where_to_draw_from_and_to
bbox
change_atoms
delete
draw
focus
get_atoms
get_package
lift
move
post_read_analysis
read_package
read_standard_values
redraw
select
simple_redraw
switch_to_order
switch_to_type
toggle_type
transform
unfocus
unselect
  __init__ 
__init__ (
        self,
        standard=None,
        atoms=(),
        package=None,
        molecule=None,
        type='n',
        order=1,
        simple_double=1,
        )

  _compute_sign_and_center 
_compute_sign_and_center ( self )

returns tuple of (sign, center) where sign is the default sign of the self.bond_width

  _decide_distance_and_center 
_decide_distance_and_center ( self )

according to molecular geometry decide what bond.center and bond.bond_width should be

  _draw_a1 
_draw_a1 ( self )

  _draw_a2 
_draw_a2 ( self )

  _draw_a3 
_draw_a3 ( self )

  _draw_adder 
_draw_adder ( self,  coords )

returns list items

  _draw_b1 
_draw_b1 ( self )

  _draw_b2 
_draw_b2 ( self )

  _draw_b3 
_draw_b3 ( self )

  _draw_d1 
_draw_d1 ( self )

  _draw_d2 
_draw_d2 ( self )

  _draw_d3 
_draw_d3 ( self )

  _draw_dash 
_draw_dash ( self,  coords )

returns list items

  _draw_h1 
_draw_h1 ( self )

  _draw_h2 
_draw_h2 ( self )

  _draw_h3 
_draw_h3 ( self )

  _draw_hatch 
_draw_hatch ( self,  coords )

returns list items

  _draw_n1 
_draw_n1 ( self )

  _draw_n2 
_draw_n2 ( self )

  _draw_n3 
_draw_n3 ( self )

  _draw_second_line 
_draw_second_line ( self,  coords )

  _draw_w1 
_draw_w1 ( self )

  _draw_w2 
_draw_w2 ( self )

  _draw_w3 
_draw_w3 ( self )

  _draw_wedge 
_draw_wedge ( self,  coords )

returns the polygon item

  _get_atom1 
_get_atom1 ( self )

atom1

  _get_atom2 
_get_atom2 ( self )

atom2

  _get_atoms 
_get_atoms ( self )

atoms

  _get_auto_bond_sign 
_get_auto_bond_sign ( self )

auto_bond_sign

  _get_bond_width 
_get_bond_width ( self )

bond_width

  _get_center 
_get_center ( self )

center

  _get_dirty 
_get_dirty ( self )

dirty override of drawable.dirty

  _get_double_length_ratio 
_get_double_length_ratio ( self )

double_length_ratio

  _get_molecule 
_get_molecule ( self )

molecule

  _get_order 
_get_order ( self )

order

  _get_parent 
_get_parent ( self )

parent

  _get_simple_double 
_get_simple_double ( self )

simple_double

  _get_type 
_get_type ( self )

type

  _get_wedge_width 
_get_wedge_width ( self )

wedge_width

  _set_atom1 
_set_atom1 ( self,  mol )

  _set_atom2 
_set_atom2 ( self,  mol )

  _set_atoms 
_set_atoms ( self,  mol )

  _set_auto_bond_sign 
_set_auto_bond_sign ( self,  mol )

  _set_bond_width 
_set_bond_width ( self,  mol )

  _set_center 
_set_center ( self,  mol )

  _set_dirty 
_set_dirty ( self,  dirty )

  _set_double_length_ratio 
_set_double_length_ratio ( self,  mol )

  _set_molecule 
_set_molecule ( self,  mol )

  _set_order 
_set_order ( self,  mol )

  _set_parent 
_set_parent ( self,  par )

  _set_simple_double 
_set_simple_double ( self,  mol )

  _set_type 
_set_type ( self,  mol )

  _set_wedge_width 
_set_wedge_width ( self,  mol )

  _where_to_draw_from_and_to 
_where_to_draw_from_and_to ( self )

  bbox 
bbox ( self )

returns the bounding box of the object as a list of [x1,y1,x2,y2]

  change_atoms 
change_atoms (
        self,
        a1,
        a2,
        )

used in overlap situations, it replaces reference to atom a1 with reference to atom a2

  delete 
delete ( self )

  draw 
draw ( self,  automatic="none" )

call the appropriate draw method, automatic specifies what to automatically compute - all, sign, none (sign is often needed to retain the look after transformation)

  focus 
focus ( self )

  get_atoms 
get_atoms ( self )

  get_package 
get_package ( self,  doc )

returns a DOM element describing the object in CDML, doc is the parent document which is used for element creation (the returned element is not inserted into the document)

  lift 
lift ( self )

  move 
move (
        self,
        dx,
        dy,
        )

moves object with his selector (when present)

  post_read_analysis 
post_read_analysis ( self )

this method is called by molecule after the whole molecule is read to perform a post-load analysis of double bond positioning

  read_package 
read_package ( self,  package )

reads the dom element package and sets internal state according to it

  read_standard_values 
read_standard_values (
        self,
        standard,
        old_standard=None,
        )

  redraw 
redraw ( self,  recalc_side=0 )

  select 
select ( self )

  simple_redraw 
simple_redraw ( self )

very fast redraw that draws only a simple line instead of the bond, used in 3d rotation only (as for bkchem 0.5.0)

  switch_to_order 
switch_to_order ( self,  order )

  switch_to_type 
switch_to_type ( self,  type )

  toggle_type 
toggle_type (
        self,
        only_shift=0,
        to_type='n',
        to_order=1,
        simple_double=1,
        )

  transform 
transform ( self,  tr )

  unfocus 
unfocus ( self )

  unselect 
unselect ( self )


Table of Contents

This document was automatically generated on Wed Jun 1 11:05:30 2005 by HappyDoc version 2.1