1 /* 2 * Copyright 2006, Haiku. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Stephan Aßmus <superstippi@gmx.de> 7 */ 8 9 #include "CommonPropertyIDs.h" 10 11 #include <stdio.h> 12 13 #include <debugger.h> 14 15 // name_for_id 16 const char* 17 name_for_id(int32 id) 18 { 19 const char* name = NULL; 20 switch (id) { 21 case PROPERTY_NAME: 22 name = "Name"; 23 break; 24 25 case PROPERTY_OPACITY: 26 name = "Opacity"; 27 break; 28 case PROPERTY_COLOR: 29 name = "Color"; 30 break; 31 32 case PROPERTY_WIDTH: 33 name = "Width"; 34 break; 35 case PROPERTY_HEIGHT: 36 name = "Height"; 37 break; 38 39 case PROPERTY_CAP_MODE: 40 name = "Caps"; 41 break; 42 case PROPERTY_JOIN_MODE: 43 name = "Joins"; 44 break; 45 case PROPERTY_MITER_LIMIT: 46 name = "Miter Limit"; 47 break; 48 case PROPERTY_STROKE_SHORTEN: 49 name = "Shorten"; 50 break; 51 52 case PROPERTY_CLOSED: 53 name = "Closed"; 54 break; 55 case PROPERTY_PATH: 56 name = "Path"; 57 break; 58 59 case PROPERTY_HINTING: 60 name = "Rounding"; 61 break; 62 case PROPERTY_MIN_VISIBILITY_SCALE: 63 name = "Min LOD"; 64 break; 65 case PROPERTY_MAX_VISIBILITY_SCALE: 66 name = "Max LOD"; 67 break; 68 69 case PROPERTY_TRANSLATION_X: 70 name = "Translation X"; 71 break; 72 case PROPERTY_TRANSLATION_Y: 73 name = "Translation Y"; 74 break; 75 case PROPERTY_ROTATION: 76 name = "Rotation"; 77 break; 78 case PROPERTY_SCALE_X: 79 name = "Scale X"; 80 break; 81 case PROPERTY_SCALE_Y: 82 name = "Scale Y"; 83 break; 84 85 case PROPERTY_DETECT_ORIENTATION: 86 name = "Detect Orient."; 87 break; 88 89 default: 90 name = "<unkown property>"; 91 break; 92 } 93 return name; 94 } 95 96