/// <summary> /// The gap at the top of the box (margin + border + pad) in layout pixels. /// </summary> internal int GapTrailing(LayoutTransform trans) { // Convert each separately to avoid rounding errors. return(trans.MpToPixelsY(Style.Margins.TrailingMp) + trans.MpToBorderPixelsY(Style.Borders.TrailingMp) + trans.MpToPixelsY(Style.Pads.TrailingMp)); }
/// <summary> /// The sum of the top and bottom gaps, that is, how much higher a box is because of /// its top and bottom margin, border, and pad. /// </summary> /// <param name="trans"></param> /// <returns></returns> internal int SurroundHeight(LayoutTransform trans) { return(GapTop(trans) + GapBottom(trans)); }
/// <summary> /// The sum of the leading and trailing gaps, that is, how much wider a box is because of /// its leading and trailing margin, border, and pad. /// </summary> /// <param name="trans"></param> /// <returns></returns> internal int SurroundWidth(LayoutTransform trans) { return(GapLeading(trans) + GapTrailing(trans)); }
public LayoutInfo(LayoutTransform source, int maxWidth, IVwGraphics graphics, IRendererFactory rf) : this(source.XOffset, source.YOffset, source.DpiX, source.DpiY, maxWidth, graphics, rf) { }
/// <summary> /// The sum of the top and bottom gaps, that is, how much higher a box is because of /// its top and bottom margin, border, and pad. /// </summary> /// <param name="trans"></param> /// <returns></returns> internal int SurroundHeight(LayoutTransform trans) { return GapTop(trans) + GapBottom(trans); }
/// <summary> /// The sum of the leading and trailing gaps, that is, how much wider a box is because of /// its leading and trailing margin, border, and pad. /// </summary> /// <param name="trans"></param> /// <returns></returns> internal int SurroundWidth(LayoutTransform trans) { return GapLeading(trans) + GapTrailing(trans); }
/// <summary> /// The gap at the top of the box (margin + border + pad) in layout pixels. /// </summary> internal int GapTrailing(LayoutTransform trans) { // Convert each separately to avoid rounding errors. return trans.MpToPixelsY(Style.Margins.TrailingMp) + trans.MpToBorderPixelsY(Style.Borders.TrailingMp) + trans.MpToPixelsY(Style.Pads.TrailingMp); }
public LayoutInfo(LayoutTransform source, int maxWidth, IVwGraphics graphics, IRendererFactory rf) : this(source.XOffset, source.YOffset, source.DpiX, source.DpiY, maxWidth, graphics, rf) { }