EnglishFrenchSpanish

Ad


OnWorks favicon

comdraw - Online in the Cloud

Run comdraw in OnWorks free hosting provider over Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

This is the command comdraw that can be run in the OnWorks free hosting provider using one of our multiple free online workstations such as Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

PROGRAM:

NAME


comdraw - drawtool with distributed command interpreter

SYNOPSIS


comdraw [-port n] [-import n] ['X-params'] [file]

DESCRIPTION


comdraw is a drawing editor with integrated command interpreter the user can interact with
via stdin and stdout (or via telnet if ACE is built in). The command syntax is a semi-
colon separated list of commands with arbitrary number of parameters enclosed in
parenthesis, with support for optional parameters and keyword arguments, i.e:

command1(arg1 arg2 arg3 :key1 val1 :key2 val2);
command2(arg1 arg2 arg3 :key1 val1 :key2 val2)

The literals and operators of C are all supported except for the syntax of the conditional
operator "?:". See the comterp documentation for more details.

All arguments to commands documented below are integers unless indicated by a suffix of
str (which are strings embedded in quotes) or flt (which are conventional floating point
numbers). "compview" is a graphical object assigned to an interpreter variable.

DRAWING COMMANDS


compview=rect(x0,y0,x1,y1) -- create a rectangle
compview=rectangle(x0,y0,x1,y1) -- same as rect
compview=line(x0,y0,x1,y1) -- create a line
compview=arrowline(x0,y0,x1,y1) -- create line with arrows
compview=ellipse(x0,y0,r1,r2) -- create a rectangle
compview=text(x0,y0 textstr) -- create a text string
compview=multiline(x0,y0[,x1,y1,...]) --
create a multiline
compview=arrowmultiline(x0,y0[,x1,y1,...]) --
create a multiline with arrows
compview=openspline(x0,y0[,x1,y1,...]) --
create an open spline
compview=arrowspline(x0,y0[,x1,y1,...]) --
create an open spline with arrows
compview=polygon(x0,y0[,x1,y1,...]) --
create a polygon
compview=closedspline(x0,y0[,x1,y1,...]) --
create a closed spline
compview=raster(x0,y0,x1,y1) --
create an empty raster

GRAPHIC STATS COMMANDS


xylist=center(compview :xy :yx :x :y :scrn) -- center of compview (dflt :xy)
rectlist=mbr(compview :lbrt :lrbt :scrn) -- minimum bounding rectangle of compview (dflt
:lbrt)
ptlist=points(compview) -- return point list from compview graphic

GRAPHIC STATE COMMANDS


font(fontnum) -- set current font from menu
brush(brushnum) -- set current brush from menu
pattern(patternnum) --
set current pattern from menu
colors(fgcolornum bgcolornum) --
set current colors from menu
colorsrgb(fgcolornum bgcolornum) -- set current colors by RGB name. The colorname
format is "#RGB" for 4 bits, "#RRGGBB" for 8 bits, #RRRGGGBBB for 12 bits,
#RRRRGGGGBBBB for 16 bits

nfonts() -- return size of font menu
nbrushes() -- return size of brush menu
npatterns() -- return size of pattern menu
ncolors() -- return size of color menus

DIRECT MANIPULATION COMMANDS


select([compview ...] :all :clear) --
make these graphics the current selection
delete(compview [compview ...]) -- delete graphic(s)
move(dx dy) -- move current selection
scale(xflt yflt) -- scale current selection
rotate(degflt) -- rotate current selection
fliph() -- horizontally flip current selection
flipv() -- vertically flip current selection

GROUP/UNGROUP COMMANDS


newgroup=growgroup(groupview compview) -- add graphic to existing group graphic
newgroup=trimgroup(groupview compview) -- remove graphic from existing group graphic

COMPONENT AND ATTRIBUTE COMMANDS


compview=setattr(compview [:keyword value [:keyword value [...]]]) -- set attributes of a
graphic component
attrlist(compview) -- return attribute list of component
compview=frame([index]) -- return composite component for a frame, defaults to current
val=at(list|attrlist|compview n :set val :ins val) -- return (or set or insert after) the
nth item in a list.
num=size(list|attrlist|compview) -- return size of a list.
compview=parent(compview) -- get parent of graphic
comp=depth(comps) -- depth-first walk of comp tree

VIEWER COMMANDS


update() -- update viewer

error=save([pathstr]) -- command to save document (to pathname)
compview=import(pathstr :popen :next) -- import graphic file from pathname or URL, or
from a command if :popen
(:next imports next in numeric series)
export(compview[,compview[,...compview]] [path] :host host_str :port port_int :socket
:string|:str :eps :idraw) -- remote in drawtool (or other) format
compview=paste(compview [xscale yscale xoff yoff | a00,a01,a10,a11,a20,a21]) -- paste
graphic into the viewer
val=pastemode([val] :get) -- toggle or set paste mode, default is 0, always paste new
graphics

ncols() -- onscreen horizontal extent in pixels
nrows() -- onscreen vertical extent in pixels

dx,dy=stod(sx,sy) -- convert from screen to drawing coordinates
sx,sy=dtos(dx,dy) -- convert from drawing to screen coordinates
dx,dy=gtod(compview gx,gy) -- convert from graphic to drawing coordinates
gx,gy=dtog(compview dx,dy) -- convert from drawing to graphic coordinates

handles(flag) --
enable/disable current selection tic marks
and/or highlighting
highlight(compview compviewgs) -- set the highlight graphic state for a graphic

zoom(zoomflt) -- zoom by factor
zoomin() -- zoom-in by 2
zoomout() -- zoom-out by 2

pan(px py) -- pan viewer
smallpanup() -- small pan up
smallpandown() -- small pan down
smallpanleft() -- small pan left
smallpanright() - small pan right
largepanup() -- large pan up
largepandown() -- large pan down
largepanleft() -- large pan left
largepanright() -- large pan right

gravity([flag]) -- set/get drawing editor gravity
gridspacing([xsize ysize]) -- set/get drawing editor grid spacing

hide(compview) -- hide graphic component
show(compview) -- show graphic component
desensitize(compview) -- desensitize graphic component
sensitize(compview) -- desensitize graphic component

IMAGING COMMANDS


tilefile(inpath outpath [xsize] [ysiz]) -- tile pgm or ppm image file
val=peek(compview x y) -- peek pixel value into raster
poke(compview x y val) -- poke pixel value into raster
pokeline(compview x y vallist) -- poke list of values into a raster line.
pcols(compview) -- number of columns in a raster
pcols(compview) -- number of rows in a raster
pflush(compview) -- flush pixels poked into a raster
pclip(compview x1,y1,x2,y2,x3,y3[,...,xn,yn]) -- clip raster with polygon
alpha(compview [alphaval]) -- set/get alpha transparency

PLOTTING COMMANDS


-- requires plotmtv and pstoedit -- barplot([var_str value_float] [...] :title title_str
:xtitle xtitle_str :ytitle ytitle_str :valtitle valtitle_str :newview) -- display a
barplot

OTHER COMMANDS


acknowledgebox(msgstr) -- popup an acknowledge dialog box
confirmbox(msgstr) -- popup a confirmation dialog box, and return 1, 0, or -1 if
cancelled

run(filename) -- run commands from file
quit() -- quit this interpreter
exit() -- exit entire application
pause([msgstr] :usec num) -- pause script execution until C/R

OPTIONS


-port n, specifies the port number to accept command interpreter connections on.

-import n, specifies the port number run the import service on. The import service
accepts connections over the net and reads drawtool format data.

-stripped n, brings up a comdraw without any menubar, toolbar, panner, slider, or zoomer.
It can be controlled via stdin or telnet if built with ACE.

-rampsize n,
selects the rampsize used for gray-level image processing.

-theight n, (or "-th n") selects the automatic raster tiling height.

-twidth n, (or "-tw n") selects the automatic raster tiling width.

-tile,
enables the automatic raster tiling.

Also see the -help message and the drawtool and idraw man pages for further options.

Use comdraw online using onworks.net services


Free Servers & Workstations

Download Windows & Linux apps

  • 1
    VirtualGL
    VirtualGL
    VirtualGL redirects 3D commands from a
    Unix/Linux OpenGL application onto a
    server-side GPU and converts the
    rendered 3D images into a video stream
    with which ...
    Download VirtualGL
  • 2
    libusb
    libusb
    Library to enable user space
    application programs to communicate with
    USB devices. Audience: Developers, End
    Users/Desktop. Programming Language: C.
    Categories...
    Download libusb
  • 3
    SWIG
    SWIG
    SWIG is a software development tool
    that connects programs written in C and
    C++ with a variety of high-level
    programming languages. SWIG is used with
    different...
    Download SWIG
  • 4
    WooCommerce Nextjs React Theme
    WooCommerce Nextjs React Theme
    React WooCommerce theme, built with
    Next JS, Webpack, Babel, Node, and
    Express, using GraphQL and Apollo
    Client. WooCommerce Store in React(
    contains: Products...
    Download WooCommerce Nextjs React Theme
  • 5
    archlabs_repo
    archlabs_repo
    Package repo for ArchLabs This is an
    application that can also be fetched
    from
    https://sourceforge.net/projects/archlabs-repo/.
    It has been hosted in OnWorks in...
    Download archlabs_repo
  • 6
    Zephyr Project
    Zephyr Project
    The Zephyr Project is a new generation
    real-time operating system (RTOS) that
    supports multiple hardware
    architectures. It is based on a
    small-footprint kernel...
    Download Zephyr Project
  • More »

Linux commands

  • 1
    4s-importJ
    4s-importJ
    4s-import � Import RDF into a 4store KB
    ...
    Run 4s-importJ
  • 2
    4s-queryJ
    4s-queryJ
    4s-query � Run SPARQL queries on a
    4store storage backend ...
    Run 4s-queryJ
  • 3
    cpuburn
    cpuburn
    cpuburn, burnBX, burnK6, burnK7,
    burnMMX, burnP5, burnP6 - a collection
    of programs to put heavy load on CPU ...
    Run cpuburn
  • 4
    cpufreq-aperf
    cpufreq-aperf
    cpufreq-aperf - Calculates the average
    frequency over a time period SYNTAX:
    cpufreq-aperf [options] DESCRIPTION: On
    latest processors exist two MSR
    registers r...
    Run cpufreq-aperf
  • 5
    g.dirsepsgrass
    g.dirsepsgrass
    g.dirseps - Internal GRASS utility for
    converting directory separator
    characters. Converts any directory
    separator characters in the input string
    to or from na...
    Run g.dirsepsgrass
  • 6
    g.extensiongrass
    g.extensiongrass
    g.extension - Maintains GRASS Addons
    extensions in local GRASS installation.
    Downloads, installs extensions from
    GRASS Addons SVN repository into local
    GRASS i...
    Run g.extensiongrass
  • More »

Ad