static Styles()
        {
            spriteAlignmentOptions    = new GUIContent[10];
            spriteAlignmentOptions[0] = EditorGUIUtilityWrap.TextContent("Center");
            spriteAlignmentOptions[1] = EditorGUIUtilityWrap.TextContent("Top Left");
            spriteAlignmentOptions[2] = EditorGUIUtilityWrap.TextContent("Top");
            spriteAlignmentOptions[3] = EditorGUIUtilityWrap.TextContent("Top Right");;
            spriteAlignmentOptions[4] = EditorGUIUtilityWrap.TextContent("Left");
            spriteAlignmentOptions[5] = EditorGUIUtilityWrap.TextContent("Right");;
            spriteAlignmentOptions[6] = EditorGUIUtilityWrap.TextContent("Bottom Left");;
            spriteAlignmentOptions[7] = EditorGUIUtilityWrap.TextContent("Bottom");;
            spriteAlignmentOptions[8] = EditorGUIUtilityWrap.TextContent("Bottom Right");;
            spriteAlignmentOptions[9] = EditorGUIUtilityWrap.TextContent("Custom");;

            s_PivotLabel               = EditorGUIUtilityWrap.TextContent("Pivot");
            s_NoSelectionWarning       = EditorGUIUtilityWrap.TextContent("No texture or sprite selected");
            s_SpriteTessellationDetail = EditorGUIUtilityWrap.TextContent("Tessellation Detail");
        }
Exemple #2
0
        static Styles()
        {
            GUIContent[] guiContentArray1 = new GUIContent[10];
            int index1 = 0;
            GUIContent guiContent1 = EditorGUIUtilityWrap.TextContent("Center");
            guiContentArray1[index1] = guiContent1;
            int index2 = 1;
            GUIContent guiContent2 = EditorGUIUtilityWrap.TextContent("Top Left");
            guiContentArray1[index2] = guiContent2;
            int index3 = 2;
            GUIContent guiContent3 = EditorGUIUtilityWrap.TextContent("Top");
            guiContentArray1[index3] = guiContent3;
            int index4 = 3;
            GUIContent guiContent4 = EditorGUIUtilityWrap.TextContent("Top Right");
            guiContentArray1[index4] = guiContent4;
            int index5 = 4;
            GUIContent guiContent5 = EditorGUIUtilityWrap.TextContent("Left");
            guiContentArray1[index5] = guiContent5;
            int index6 = 5;
            GUIContent guiContent6 = EditorGUIUtilityWrap.TextContent("Right");
            guiContentArray1[index6] = guiContent6;
            int index7 = 6;
            GUIContent guiContent7 = EditorGUIUtilityWrap.TextContent("Bottom Left");
            guiContentArray1[index7] = guiContent7;
            int index8 = 7;
            GUIContent guiContent8 = EditorGUIUtilityWrap.TextContent("Bottom");
            guiContentArray1[index8] = guiContent8;
            int index9 = 8;
            GUIContent guiContent9 = EditorGUIUtilityWrap.TextContent("Bottom Right");
            guiContentArray1[index9] = guiContent9;
            int index10 = 9;
            GUIContent guiContent10 = EditorGUIUtilityWrap.TextContent("Custom");
            guiContentArray1[index10] = guiContent10;

            Styles.spriteAlignmentOptions = guiContentArray1;
            GUIContent[] guiContentArray2 = new GUIContent[3];
            int index11 = 0;
            GUIContent guiContent11 = EditorGUIUtilityWrap.TextContent("Delete Existing|Delete all existing sprite assets before the slicing operation");
            guiContentArray2[index11] = guiContent11;
            int index12 = 1;
            GUIContent guiContent12 = EditorGUIUtilityWrap.TextContent("Smart|Try to match existing sprite rects to sliced rects from the slicing operation");
            guiContentArray2[index12] = guiContent12;
            int index13 = 2;
            GUIContent guiContent13 = EditorGUIUtilityWrap.TextContent("Safe|Keep existing sprite rects intact");
            guiContentArray2[index13] = guiContent13;
            Styles.slicingMethodOptions = guiContentArray2;
            Styles.methodLabel = EditorGUIUtilityWrap.TextContent("Method");
            Styles.pivotLabel = EditorGUIUtilityWrap.TextContent("Pivot");
            Styles.typeLabel = EditorGUIUtilityWrap.TextContent("Type");
            Styles.sliceButtonLabel = EditorGUIUtilityWrap.TextContent("Slice");
            Styles.columnAndRowLabel = EditorGUIUtilityWrap.TextContent("Column & Row");
            Styles.columnLabel = EditorGUIUtilityWrap.TextContent("C");
            Styles.rowLabel = EditorGUIUtilityWrap.TextContent("R");
            Styles.pixelSizeLabel = EditorGUIUtilityWrap.TextContent("Pixel Size");
            Styles.xLabel = EditorGUIUtilityWrap.TextContent("X");
            Styles.yLabel = EditorGUIUtilityWrap.TextContent("Y");
            Styles.offsetLabel = EditorGUIUtilityWrap.TextContent("Offset");
            Styles.paddingLabel = EditorGUIUtilityWrap.TextContent("Padding");
            Styles.automaticSlicingHintLabel = EditorGUIUtilityWrap.TextContent("To obtain more accurate slicing results, manual slicing is recommended!");
            Styles.customPivotLabel = EditorGUIUtilityWrap.TextContent("Custom Pivot");
        }