GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Visio(3) User Contributed Perl Documentation Visio(3)

Visio - Perl extension mainpulating XML based Visio files

To create a viso vdx file, create multiple pages, reorient one of the pages:

  my $v = new Visio();
  $v->set_title('wabla wabla');
  $v->set_timeCreated();
  $v->set_timeSaved()

  my $page = $v->addpage();
  $page->set_name('my page');
  $page->set_heightWidth(8,11);

  my $page2 = $v->addpage();
  $page2->set_name('my page2');

  $v->toFile('myvisofile.vdx');

  Visio is an alpha stage library to create and manipulate Microsoft Visio
  drawings.

  Visio is an alpha stage library to create and manipulate Microsoft Visio
  drawings.

  Currently it can only create drawings from scratch, and can not
  create a usable object model from a pre-existing file.

  The Visio module is however able to extract stencils from pre-existing
  files and insert them into your new drawings. This is helpfull as 
  it is fairly difficult to make a nice drawing on your own via the 
  current Visio perl module API.

  This is my first public Perl module, and I'm sure there are tons of 
  mistakes. Please feel free to communicate any design flaws or reworking
  you may feel would make Visio more usable and approachable.

A new Visio document is created using the new method:

 my $vDoc = new Visio();

By default the document is completely empty and the document creator is set to 'perl-visio'. This can be overwritten by use of the set_creator method.

Visio document is returned as an XML string.

 my $vString = $vDoc->toString;

Visio doc is written out to an XML file.

 $vDoc->toFile('myfile.vdx');

libxml2 doc element is returned

 $vDoc->toXmlDoc();

Sets Document title

 $vDoc->set_title('my title');

Sets Document subject

 $vDoc->set_subject('my subject');

Sets Document manager field

 $vDoc->set_manager('my manager');

Sets company filed in document.

 $vDoc->set_company('my company');

Sets Document description.

 $vDoc->set_desc('my really good description');

Sets Document creator field.

 $vDoc->set_creator('just me');

Set's document time created information. If time is not passed, the current time (UTC) is set.

 $vDoc->set_timeCreated();

Set's document time saved information. If time is not passed, the current time (UTC) is set.

 $vDoc->set_timeSaved();

Takes in argument of $time, which is in the format of the perl time() function. Returns a $visioTimeString formatted string.

 $vDoc->set_timeCreated(Visio::visio_timeformat(time()));
 
 is equivilent to:

 $vDoc->set_timeCreated();

searches the visio masters (stencils). filters can be specifed:

 $vDoc->find_master_dom({name=>'myrectangle'})

returns a libxml nodelist object of all stencils that had name 'myractangle'. Not specifying filters returns all stencils.

filters avaliable:

name

A new Visio page is created in a Visio document.

 my $vPage1 = $vDoc->addpage();

By default the document is completely empty and the document creator is set to 'perl-visio'. This can be overwritten by use of the set_creator method.

Sets the name of the page

 $vPage->set_name('mypage');

Sets a page's height and width. In inches by default:

 $vPage->setheightWidth(8,11);

creates a pageSheet method if needed under this page

    my $pageSheet = $vPage->create_pageSheet();

For the most part one shouldn't need to directly use these methods

new creates (if one does not already exist) a new child PageSheet element node under $parentNode, which is a libxml2 object.

returns the PageSheet libxml2 node

 my $pageSheetNode = $pageSheet->getnode();

creates a PageProps object and element under the current PageSheet

For the most part one shouldn't need to directly use these methods

new creates (if one does not already exist) a new child PageProps element node under $parentNode, which is a libxml2 object.

returns the PageProps libxml2 node

 my $pagePropsNode = $pageProps->getnode();

sets the page width of this PageProps node. Default unit is in inches.

 $pageProps->set_PageWidth($width);

sets the page height of this PageProps node. Default unit is in inches.

 $pageProps->set_PageHeight($height);

None by default.

If you have a mailing list set up for your module, mention it here.

Aamer Akhter, <aakhter@cisco.com> <aakhter@gmail.com>

Copyright 2005 by Aamer Akhter

This library is free software; you can redistribute it and/or modify it under the same terms as in LICENSE and MSPATENTLICENSE files.

 "This product may incorporate intellectual property owned by 
 Microsoft Corporation. The terms and conditions upon which Microsoft 
 is licensing such intellectual property may be found at 
 http://msdn.microsoft.com/library/en-us/odcXMLRef/html/odcXMLRefLegalNotice.asp"
2005-08-13 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.