コード例 #1
0
ファイル: GUIListView.cs プロジェクト: zz5756712/bsf
        /// <summary>
        /// Creates a new empty list view.
        /// </summary>
        /// <param name="width">Width of the list view, in pixels.</param>
        /// <param name="height">Height of the list view, in pixels.</param>
        /// <param name="entryHeight">Height of a single element in the list, in pixels.</param>
        /// <param name="layout">GUI layout into which the list view will be placed into.</param>
        protected GUIListViewBase(int width, int height, int entryHeight, GUILayout layout)
        {
            scrollArea = new GUIScrollArea(ScrollBarType.ShowIfDoesntFit, ScrollBarType.NeverShow,
                                           GUIOption.FixedWidth(width), GUIOption.FixedHeight(height));
            layout.AddElement(scrollArea);

            topPadding    = new GUILabel(new LocString());
            bottomPadding = new GUILabel(new LocString());

            scrollArea.Layout.AddElement(topPadding);
            scrollArea.Layout.AddElement(bottomPadding);

            this.width       = width;
            this.height      = height;
            this.entryHeight = entryHeight;
        }
コード例 #2
0
ファイル: GUILabel.cs プロジェクト: zz5756712/bsf
 private static extern void Internal_CreateInstance(GUILabel instance, ref GUIContent content, string style,
                                                    GUIOption[] options);