The SRP Sketch Control creates a multilayered vector graphic that can be saved to the OpenInsight database and exported to various file formats for distribution or printing. It is unique in that it far more self-contained than other controls. Instead of creating a form and wiring up a bunch of buttons and events, the SRP Sketch Control contains all its own controls and has very few events at all. It's a turnkey solution to meet the demands of specific industries.

As a developer, you will create a form that contains the SRP Sketch Control and do some work to set it up. Once the setup is established, the SRP Sketch Control will take care of the rest. When the user is ready to save, they will use the same save commands as the rest of your application, at which point you will read the control's Data property and save it anywhere you wish. You will find this control to be one of the easiest to integrate into your application.

The Sketch

While the ultimate goal of the SRP Sketch Control is to create a single image for printing or viewing, the sketch itself is a bit more complex. It consists of three layers: shapes, text, and icons.

This means that no matter what order you draw certain elements, Icons will always obscure both Shapes and Text, but shapes will never obscure text. Additionally, the text layer does something known as clipping. This is when the boundaries of the text "erase" everything beneath it. This makes labeling very readable as seen here:

The separation of layers makes diagram maintenance easier. When it comes time to export the diagram to a single image, the layers are composited and the image can then be used just about anywhere, including OIPI.

There are only two options for sketch sizes available to the user, which they will select from the toolbar: Half Page and Full Page. The size really only affects the ration of the image. Half page could be thought of as landscape since there is no reason it couldn't be drawn to fill an entire landscape page. Full page is more like a portrait. The half page size is the default since most reports will display the sketch in a smaller portion of a page rather than the whole page.

  • No labels