Quantcast
Channel: MicroStation Programming - Forum - Recent Threads
Viewing all articles
Browse latest Browse all 1677

mdlTransients_* - interfering with fit view

$
0
0

Hi all,

    In my app I'm updating from V7 -> V8 there is a guide drawn around the edge of the window from which the user user can work out where they are, picture a blue border, 50-60 pixels wide drawn around the edge of the display with lat/lon written on it. This border does not change size, depending upon the amount of zoom employed, it is always the 50-60 pixels.

    This used to be achieved by just creating an appropriate sized shape and then calling mdlElement_draw() . The function containing this this was controlled by an mdlView_setFunction(UPDATE_POST, ....) command. Now in the brave new world of V8, this no longer works and I'm using Transients. A couple of hours of work, some googling etc and everything is fine except for one thing, fit to view.

    In the old method, the shape that was drawn was not taken into account when the internals of MS did the calc's for the fit. The data would show up nicely, the longest horizontal element would be about 95% of the width of the display. Now, it appears that MS is taking into account the transients hence when fit view is called the first time, everything is fine. When it is called the second time, the extents of the transients appear to be taken and the scaling based upon this. This results in the normal elements being scaled 95%, but the border is still drawn at the edge of the screen. Call fit view a few times and the normal elements, the data the user is interested in, shrinks and shrinks with each call.

    Is there a way that the fit view scaling can be told to ignore the transients?

Any thoughts, greatly appreciated,

       Andrew

p.s. If this is making no sense, let me know and I can do some screen grabs


Viewing all articles
Browse latest Browse all 1677

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>