当前位置: 首页>>代码示例>>C#>>正文


C# OLVListItem.GetSubItemBounds方法代码示例

本文整理汇总了C#中BrightIdeasSoftware.OLVListItem.GetSubItemBounds方法的典型用法代码示例。如果您正苦于以下问题:C# OLVListItem.GetSubItemBounds方法的具体用法?C# OLVListItem.GetSubItemBounds怎么用?C# OLVListItem.GetSubItemBounds使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BrightIdeasSoftware.OLVListItem的用法示例。


在下文中一共展示了OLVListItem.GetSubItemBounds方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: CalculateCellEditorBounds

 /// <summary>
 /// Calculate the bounds of the edit control for the given item/column
 /// </summary>
 /// <param name="item"></param>
 /// <param name="subItemIndex"></param>
 /// <returns></returns>
 public Rectangle CalculateCellEditorBounds(OLVListItem item, int subItemIndex)
 {
     Rectangle r;
     if (this.View == View.Details)
         r = item.GetSubItemBounds(subItemIndex);
     else
         r = this.GetItemRect(item.Index, ItemBoundsPortion.Label);
     if (this.OwnerDraw)
         return CalculateCellEditorBoundsOwnerDrawn(item, subItemIndex, r);
     else
         return CalculateCellEditorBoundsStandard(item, subItemIndex, r);
 }
开发者ID:ZlayaZhaba,项目名称:XervBackup,代码行数:18,代码来源:ObjectListView.cs

示例2: CalculateItemBounds

        /// <summary>
        /// Given the item and the subitem, calculate its bounds.
        /// </summary>
        /// <param name="item"></param>
        /// <param name="subItem"></param>
        /// <returns></returns>
        public Rectangle CalculateItemBounds(OLVListItem item, OLVListSubItem subItem) {
            if (item == null)
                return Rectangle.Empty;

            if (subItem == null)
                return item.Bounds;
            else
                return item.GetSubItemBounds(item.SubItems.IndexOf(subItem));
        }
开发者ID:VicBoss,项目名称:KR,代码行数:15,代码来源:Adornments.cs

示例3: bg_brush

        public Brush bg_brush(OLVListItem item, int col_idx) {
            match_item i = item.RowObject as match_item;
            int row_idx = item.Index;

            if (col_idx == parent_.msgCol.fixed_index()) {
                bool is_sel = !ignore_selection ? parent_.multi_sel_idx.Contains(row_idx) : false;
                if (!is_sel && app.inst.use_bg_gradient) {
                    Rectangle r = item.GetSubItemBounds(col_idx);
                    if ( r.Width > 0 && r.Height > 0)
                        return gradient_.brush(r, app.inst.bg_from, app.inst.bg_to);
                }
            }

            return brush_.brush( bg_color(item, col_idx));
        }
开发者ID:printedheart,项目名称:logwizard,代码行数:15,代码来源:log_view_item_draw_ui.cs

示例4: CalculateCellEditorBounds

 /// <summary>
 /// Calculate the bounds of the edit control for the given item/column
 /// </summary>
 /// <param name="item"></param>
 /// <param name="subItemIndex"></param>
 /// <param name="preferredSize"> </param>
 /// <returns></returns>
 public Rectangle CalculateCellEditorBounds(OLVListItem item, int subItemIndex, Size preferredSize)
 {
     Rectangle r = this.View == View.Details
         ? item.GetSubItemBounds(subItemIndex)
         : this.GetItemRect(item.Index, ItemBoundsPortion.Label);
     return this.OwnerDraw
         ? CalculateCellEditorBoundsOwnerDrawn(item, subItemIndex, r, preferredSize)
         : CalculateCellEditorBoundsStandard(item, subItemIndex, r, preferredSize);
 }
开发者ID:FOSBOS,项目名称:diNo,代码行数:16,代码来源:ObjectListView.cs

示例5: bg_color

        public Color bg_color(OLVListItem item, int col_idx) {
            match_item i = item.RowObject as match_item;
            int row_idx = item.Index;

            Color color;
            bool is_sel = !ignore_selection ? parent_.multi_sel_idx.Contains(row_idx) : false;

            Color bg = i.bg(parent_);
            Color dark_bg = i.sel_bg(parent_);

            if (col_idx == parent_.msgCol.fixed_index()) {
                if (is_sel) 
                    color = is_sel ? dark_bg : bg;
                else if (app.inst.use_bg_gradient) {
                    Rectangle r = item.GetSubItemBounds(col_idx);
                    if (r.Width > 0 && r.Height > 0)
                        // it's a gradient
                        color = util.transparent;
                    else
                        color = bg;
                } else
                    color = bg;
            } else 
                color = is_sel ? dark_bg : bg;

            if (color == util.transparent)
                color = app.inst.bg;
            return color;
        }
开发者ID:printedheart,项目名称:logwizard,代码行数:29,代码来源:log_view_item_draw_ui.cs


注:本文中的BrightIdeasSoftware.OLVListItem.GetSubItemBounds方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。