Lars Gullik Bjønnes wrote:

>   int const xoffset_l = max(0, params.bb.xl - xl_orig);
>   int const xoffset_r = max(0, image_->w - params.bb.xr + xl_orig);
>   int const yoffset_t = max(0, image_->h - params.bb.yt + yb_orig);
>   int const yoffset_b = max(0, params.bb.yb - yb_orig);
> 
> looks a lot better...


must be:

   int const xoffset_l = max(0, (int)params.bb.xl - xl_orig);
   int const xoffset_r = max(0, image_->w - (int)params.bb.xr + xl_orig);
   int const yoffset_t = max(0, image_->h - (int)params.bb.yt + yb_orig);
   int const yoffset_b = max(0, (int)params.bb.yb - yb_orig);

or is there a better way?

Herbert



-- 
http://www.lyx.org/help/

Reply via email to