NK

Hi! I'm trying to draw lines across a model canvass through report scripting and I need to get the actual width and height of the canvass to set my line endpoints. I tried 

model.Graphic(false, false, locale).getWidth(Constants.SIZE_PIXEL) 

to get the width but it only captures the  width of the picture representation of the model. The resulting width fell short of the actual width of the model canvass. Are there any ways or methods to get the actual height and width of the model template /canvass through Report Scripting?

by Freddy Barkhuizen
Posted on Thu, 03/31/2011 - 23:48

Good day,

Have a look at the BoundingRect ( ) method on the Model Object:

 

Returns the smallest rectangle in which all model items are contained.     

Return value

 

int[]

int[3] The rectangle determined: x=Array(0), y=Array(1), width=Array(2), height=Array(3).

 

0
by Nanji Katana Author
Posted on Fri, 04/01/2011 - 18:23

Hi Fred,

I already tried that before but just like the getWidth(...) function, the dimensions that were returned fell short of the actual canvass dimensions. I was really aiming for plotting grid lines independent from the positioning of any items drawn on it. My aim was just to draw the line even before any objects are inserted into the model... For now, I just relied on some running width computations on how the lines will be drawn. Thanks for the advice though. Happy weekend!!

0
by Nanji Katana Author
Posted on Fri, 04/01/2011 - 18:22

It will be also better if model canvass width can be set through report scripting.

0

Featured achievement

Rookie
Say hello to the ARIS Community! Personalize your community experience by following forums or tags, liking a post or uploading a profile picture.
Recent Unlocks

Leaderboard

|
icon-arrow-down icon-arrow-cerulean-left icon-arrow-cerulean-right icon-arrow-down icon-arrow-left icon-arrow-right icon-arrow icon-back icon-close icon-comments icon-correct-answer icon-tick icon-download icon-facebook icon-flag icon-google-plus icon-hamburger icon-in icon-info icon-instagram icon-login-true icon-login icon-mail-notification icon-mail icon-mortarboard icon-newsletter icon-notification icon-pinterest icon-plus icon-rss icon-search icon-share icon-shield icon-snapchat icon-star icon-tutorials icon-twitter icon-universities icon-videos icon-views icon-whatsapp icon-xing icon-youtube icon-jobs icon-heart icon-heart2 aris-express bpm-glossary help-intro help-design Process_Mining_Icon help-publishing help-administration help-dashboarding help-archive help-risk icon-knowledge icon-question icon-events icon-message icon-more icon-pencil forum-icon icon-lock