public void OnSideGUI() { var atlasTexture = this.tileset.AtlasTexture; float restoreLabelWidth = EditorGUIUtility.labelWidth; EditorGUIUtility.labelWidth = 85; Rect position = EditorGUILayout.BeginVertical(GUILayout.Width(210)); GUILayout.Space(6); this.scrollingInfo = EditorGUILayout.BeginScrollView(this.scrollingInfo, RotorzEditorStyles.Instance.PaddedScrollView); if (this.autotileTileset != null) { GUILayout.Label(TileLang.Text("Autotile Atlas"), RotorzEditorStyles.Instance.BoldLabel); } else { GUILayout.Label(TileLang.Text("Atlas"), RotorzEditorStyles.Instance.BoldLabel); } ++EditorGUI.indentLevel; if (this.autotileTileset != null) { EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Layout"), this.autotileTileset.AutotileLayout.ToString()); EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Inner Joins"), TileLang.FormatYesNoStatus(this.autotileTileset.HasInnerJoins)); GUILayout.Space(6); } EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Type"), this.tileset.procedural ? TileLang.Text("Procedural") : TileLang.Text("Non-Procedural")); if (atlasTexture != null) { EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Width"), TileLang.FormatPixelMetric(atlasTexture.width)); EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Height"), TileLang.FormatPixelMetric(atlasTexture.height)); GUILayout.Space(6); } EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Rows"), this.tileset.Rows.ToString()); EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Columns"), this.tileset.Columns.ToString()); --EditorGUI.indentLevel; GUILayout.Space(6); GUILayout.Label(TileLang.ParticularText("Property", "Tile Size"), RotorzEditorStyles.Instance.BoldLabel); ++EditorGUI.indentLevel; EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Width"), TileLang.FormatPixelMetric(this.tileset.TileWidth)); EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Height"), TileLang.FormatPixelMetric(this.tileset.TileHeight)); --EditorGUI.indentLevel; GUILayout.Space(6); GUILayout.Label(TileLang.Text("Edge Correction"), RotorzEditorStyles.Instance.BoldLabel); ++EditorGUI.indentLevel; EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Border"), TileLang.FormatPixelMetric(this.tileset.BorderSize)); EditorGUILayout.LabelField(TileLang.ParticularText("Property", "Delta"), TileLang.FormatPixelFractionMetric(this.tileset.Delta)); --EditorGUI.indentLevel; EditorGUILayout.EndScrollView(); EditorGUILayout.EndVertical(); if (Event.current.type == EventType.Repaint) { RotorzEditorStyles.Instance.HorizontalSplitter.Draw( new Rect(position.x, position.y, position.width - 6, position.height), GUIContent.none, false, false, false, false ); } EditorGUIUtility.labelWidth = restoreLabelWidth; }