Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

py_color.C File Reference

#include "py_commands.h"
#include "VMDApp.h"

Go to the source code of this file.

Functions

PyObject * py_categories (PyObject *self, PyObject *args)
PyObject * py_get_colormap (PyObject *self, PyObject *args, PyObject *kwargs)
PyObject * py_set_colormap (PyObject *self, PyObject *args, PyObject *kwargs)
PyObject * py_get_colors (PyObject *self, PyObject *args)
PyObject * py_get_colorlist (PyObject *self, PyObject *args)
PyObject * py_set_colors (PyObject *self, PyObject *args, PyObject *kwargs)
PyObject * py_set_colorid (PyObject *self, PyObject *args, PyObject *kwargs)
PyObject * py_scale_method (PyObject *self, PyObject *args)
PyObject * py_scale_methods (PyObject *self, PyObject *args)
PyObject * py_scale_midpoint (PyObject *self, PyObject *args)
PyObject * py_scale_min (PyObject *self, PyObject *args)
PyObject * py_scale_max (PyObject *self, PyObject *args)
PyObject * py_scale_reverse (PyObject *self, PyObject *args)
PyObject * py_scale_posterize (PyObject *self, PyObject *args)
PyObject * py_set_scale (PyObject *self, PyObject *args, PyObject *kwargs)
PyObject * initcolor ()

Variables

const char categories_doc []
const char get_colormap_doc []
const char set_colormap_doc []
const char get_colors_doc []
const char get_colorlist_doc []
const char set_colors_doc []
const char set_colorid_doc []
const char scale_method_doc []
const char scale_methods_doc []
const char scale_midpoint_doc []
const char scale_min_doc []
const char scale_max_doc []
const char scale_reverse_doc []
const char scale_posterize_doc []
const char set_scale_doc []
PyMethodDef ColorMethods []
const char color_moddoc []


Function Documentation

PyObject* initcolor  
 

Definition at line 571 of file py_color.C.

References color_moddoc, and ColorMethods.

PyObject* py_categories PyObject *    self,
PyObject *    args
[static]
 

Definition at line 28 of file py_color.C.

References as_pystring, VMDApp::color_category, get_vmdapp, NULL, num, and VMDApp::num_color_categories.

PyObject* py_get_colorlist PyObject *    self,
PyObject *    args
[static]
 

Definition at line 210 of file py_color.C.

References VMDApp::color_name, VMDApp::color_value, get_vmdapp, NULL, and VMDApp::num_regular_colors.

PyObject* py_get_colormap PyObject *    self,
PyObject *    args,
PyObject *    kwargs
[static]
 

Definition at line 61 of file py_color.C.

References as_pystring, VMDApp::color_category_item, VMDApp::color_mapping, get_vmdapp, NULL, and VMDApp::num_color_category_items.

PyObject* py_get_colors PyObject *    self,
PyObject *    args
[static]
 

Definition at line 164 of file py_color.C.

References VMDApp::color_name, VMDApp::color_value, get_vmdapp, NULL, and VMDApp::num_regular_colors.

PyObject* py_scale_max PyObject *    self,
PyObject *    args
[static]
 

Definition at line 443 of file py_color.C.

References VMDApp::colorscale_params, get_vmdapp, and NULL.

PyObject* py_scale_method PyObject *    self,
PyObject *    args
[static]
 

Definition at line 359 of file py_color.C.

References as_pystring, VMDApp::colorscale_method_current, VMDApp::colorscale_method_name, get_vmdapp, and NULL.

PyObject* py_scale_methods PyObject *    self,
PyObject *    args
[static]
 

Definition at line 376 of file py_color.C.

References as_pystring, VMDApp::colorscale_method_name, get_vmdapp, NULL, num, and VMDApp::num_colorscale_methods.

PyObject* py_scale_midpoint PyObject *    self,
PyObject *    args
[static]
 

Definition at line 407 of file py_color.C.

References VMDApp::colorscale_params, get_vmdapp, and NULL.

PyObject* py_scale_min PyObject *    self,
PyObject *    args
[static]
 

Definition at line 425 of file py_color.C.

References VMDApp::colorscale_params, get_vmdapp, and NULL.

PyObject* py_scale_posterize PyObject *    self,
PyObject *    args
[static]
 

Definition at line 479 of file py_color.C.

References as_pyint, VMDApp::colorscale_params, get_vmdapp, and NULL.

PyObject* py_scale_reverse PyObject *    self,
PyObject *    args
[static]
 

Definition at line 461 of file py_color.C.

References as_pyint, VMDApp::colorscale_params, get_vmdapp, and NULL.

PyObject* py_set_colorid PyObject *    self,
PyObject *    args,
PyObject *    kwargs
[static]
 

Definition at line 328 of file py_color.C.

References VMDApp::color_change_rgb, VMDApp::color_name, get_vmdapp, NULL, and VMDApp::num_regular_colors.

PyObject* py_set_colormap PyObject *    self,
PyObject *    args,
PyObject *    kwargs
[static]
 

Definition at line 110 of file py_color.C.

References as_constcharptr, VMDApp::color_change_name, get_vmdapp, NULL, and result.

PyObject* py_set_colors PyObject *    self,
PyObject *    args,
PyObject *    kwargs
[static]
 

Definition at line 257 of file py_color.C.

References as_constcharptr, VMDApp::color_change_rgb, VMDApp::color_index, get_vmdapp, and NULL.

PyObject* py_set_scale PyObject *    self,
PyObject *    args,
PyObject *    kwargs
[static]
 

Definition at line 502 of file py_color.C.

References VMDApp::colorscale_method_index, VMDApp::colorscale_params, VMDApp::colorscale_setmethod, VMDApp::colorscale_setparams, get_vmdapp, midpoint, and NULL.


Variable Documentation

const char categories_doc[] [static]
 

Initial value:

"Get available color categories\n\n"
"Returns:\n"
"    (list of str): Available color categories"

Definition at line 24 of file py_color.C.

const char color_moddoc[] [static]
 

Initial value:

"Contains methods for working with colors, including changing color "
"definitions, color maps, or edit the color scale. All RGB and color scale "
"values should be in the range 0 to 1"

Definition at line 554 of file py_color.C.

Referenced by initcolor.

PyMethodDef ColorMethods[] [static]
 

Initial value:

 {
  {"categories", (PyCFunction)py_categories, METH_NOARGS, categories_doc},
  {"get_colormap", (PyCFunction)py_get_colormap, METH_VARARGS | METH_KEYWORDS, get_colormap_doc},
  {"set_colormap", (PyCFunction)py_set_colormap, METH_VARARGS | METH_KEYWORDS, set_colormap_doc},
  {"get_colors", (PyCFunction)py_get_colors, METH_NOARGS, get_colors_doc},
  {"get_colorlist", (PyCFunction)py_get_colorlist, METH_NOARGS, get_colorlist_doc},
  {"set_colors", (PyCFunction)py_set_colors, METH_VARARGS | METH_KEYWORDS, set_colors_doc},
  {"set_colorid", (PyCFunction)py_set_colorid, METH_VARARGS | METH_KEYWORDS, set_colorid_doc},
  {"scale_method", (PyCFunction)py_scale_method, METH_NOARGS, scale_method_doc},
  {"scale_methods", (PyCFunction)py_scale_methods, METH_NOARGS, scale_methods_doc},
  {"scale_midpoint", (PyCFunction)py_scale_midpoint, METH_NOARGS, scale_midpoint_doc},
  {"scale_min", (PyCFunction)py_scale_min, METH_NOARGS, scale_min_doc},
  {"scale_max", (PyCFunction)py_scale_max, METH_NOARGS, scale_max_doc},
  {"scale_reverse", (PyCFunction)py_scale_reverse, METH_NOARGS, scale_reverse_doc},
  {"scale_posterize", (PyCFunction)py_scale_posterize, METH_NOARGS, scale_posterize_doc},
  {"set_scale", (PyCFunction)py_set_scale, METH_VARARGS | METH_KEYWORDS, set_scale_doc},
  {NULL, NULL}
}

Definition at line 534 of file py_color.C.

Referenced by initcolor.

const char get_colorlist_doc[] [static]
 

Initial value:

"Get list of all defined colors by RGB value\n\n"
"Returns:\n"
"    (list of 3-tuple): Currently defined RGB values"

Definition at line 206 of file py_color.C.

const char get_colormap_doc[] [static]
 

Initial value:

"Get name/color pairs in a given colormap category\n\n"
"Args:\n"
"    name (str): Colormap to query\n\n"
"Returns:\n"
"   (dict str->str): Name/color pairs in colormap"

Definition at line 55 of file py_color.C.

const char get_colors_doc[] [static]
 

Initial value:

"Get all legal color names and corresponding RGB values.\n\n"
"Returns:\n"
"    (dict str->3 tuple of float): Color name and RGB value. RGB values\n"
"        should be in the range 0 to 1."

Definition at line 159 of file py_color.C.

const char scale_max_doc[] [static]
 

Initial value:

"Get current colorscale max.\n\n"
"Returns:\n"
"    (float) Current maximum value"

Definition at line 439 of file py_color.C.

const char scale_method_doc[] [static]
 

Initial value:

"Get the current colorscale method\n\n"
"Returns:\n"
"    (str) Current method name"

Definition at line 355 of file py_color.C.

const char scale_methods_doc[] [static]
 

Initial value:

"Get list of available colorscale methods\n\n"
"Returns:\n"
"    (list of str) Available colorscale methods"

Definition at line 372 of file py_color.C.

const char scale_midpoint_doc[] [static]
 

Initial value:

"Get current colorscale midpoint value\n\n"
"Returns:\n"
"    (float) Current midpoint"

Definition at line 403 of file py_color.C.

const char scale_min_doc[] [static]
 

Initial value:

"Get current colorscale minimum value\n\n"
"Returns:\n"
"    (float): Current minimum"

Definition at line 421 of file py_color.C.

const char scale_posterize_doc[] [static]
 

Initial value:

"Get current colorscale posterization count.\n\n"
"Returns:\n"
"    (int) Color scale posterization count"

Definition at line 475 of file py_color.C.

const char scale_reverse_doc[] [static]
 

Initial value:

"Get current colorscale reversal flag.\n\n"
"Returns:\n"
"    (int) Reversed color scale flag"

Definition at line 457 of file py_color.C.

const char set_colorid_doc[] [static]
 

Initial value:

"Set RGB value of a color at a given index\n\n"
"Args:\n"
"    id (int): Color ID to change\n"
"    rgb (3-tuple of floats): New RGB value for color. Values should be in\n"
"        the range 0 to 1."

Definition at line 322 of file py_color.C.

const char set_colormap_doc[] [static]
 

Initial value:

"Update name/color pairs in given color category\n\n"
"Args:\n"
"    name (str): Name of colormap to update\n"
"    pairs (dict str->str): Colors to update and new values. Keys must come\n"
"        from the keys listed by `get_colormap` for that color category. Not\n"
"        all keys need to be listed. Values must be legal color names"

Definition at line 103 of file py_color.C.

const char set_colors_doc[] [static]
 

Initial value:

"Change the RGB values for named colors.\n\n"
"Args:\n"
"    colors (dict str->3-tuple of floats): Name and RGB values for colors \n"
"        to update. RGB values should be in the range 0 to 1."

Definition at line 252 of file py_color.C.

const char set_scale_doc[] [static]
 

Initial value:

"Set colorscale parameters. One or more parameters may be set with each "
"function invocation.\n\n"
"Args:\n"
"    method (str): Coloring method. Valid values are in scale_methods()\n"
"    midpoint (float): Midpoint of color scale\n"
"    min (float): Minimum value of color scale\n"
"    max (float): Maximum value of color scale\n"
"    reverse (int): Reverse color scale order\n"

Definition at line 493 of file py_color.C.


Generated on Mon Dec 9 02:45:30 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002