Просмотр исходного кода

New UI theme to match global Polycode redesign, made Cocoa core apply antialiasing on setVideoMode, fixed color creation from hex, made build tool respect vsync and AF settings

Ivan Safrin 13 лет назад
Родитель
Сommit
a6bb676068
96 измененных файлов с 383 добавлено и 371 удалено
  1. BIN
      Assets/Icons/Icon_base.psd
  2. BIN
      Assets/Icons/app_file_icon.icns
  3. BIN
      Assets/Icons/app_file_icon.png
  4. BIN
      Assets/Icons/file_icon_base.psd
  5. BIN
      Assets/Icons/main_icon.icns
  6. BIN
      Assets/Icons/main_icon.png
  7. BIN
      Assets/Icons/player_icon.icns
  8. BIN
      Assets/Icons/player_icon.png
  9. BIN
      Assets/Icons/polycode_project.icns
  10. BIN
      Assets/Icons/polycode_project.png
  11. BIN
      Assets/UIThemes.pak
  12. BIN
      Assets/UIThemes/default/button.png
  13. BIN
      Assets/UIThemes/default/buttonFocused.png
  14. BIN
      Assets/UIThemes/default/checkbox_checked.png
  15. BIN
      Assets/UIThemes/default/checkbox_unchecked.png
  16. BIN
      Assets/UIThemes/default/closeIcon.png
  17. BIN
      Assets/UIThemes/default/colorboxBg.png
  18. BIN
      Assets/UIThemes/default/colorboxFrame.png
  19. BIN
      Assets/UIThemes/default/combobox_bg.png
  20. BIN
      Assets/UIThemes/default/combobox_drop.png
  21. BIN
      Assets/UIThemes/default/hsliderBg.png
  22. BIN
      Assets/UIThemes/default/hsliderHandle.png
  23. BIN
      Assets/UIThemes/default/menu_bg.png
  24. BIN
      Assets/UIThemes/default/menu_selector.png
  25. BIN
      Assets/UIThemes/default/selector.png
  26. BIN
      Assets/UIThemes/default/textfield.png
  27. BIN
      Assets/UIThemes/default/textfield_multi.png
  28. 57 47
      Assets/UIThemes/default/theme.xml
  29. BIN
      Assets/UIThemes/default/treeBg.png
  30. BIN
      Assets/UIThemes/default/treeCellBg.png
  31. BIN
      Assets/UIThemes/default/windowBg.png
  32. 11 10
      Core/Contents/Include/PolyColor.h
  33. 51 106
      Core/Contents/Source/PolyCocoaCore.mm
  34. 7 7
      Core/Contents/Source/PolyColor.cpp
  35. 1 1
      IDE/Contents/Include/PolycodeTextEditor.h
  36. BIN
      IDE/Contents/Resources/Fonts/Roboto-Thin.ttf
  37. BIN
      IDE/Contents/Resources/Images/barClose.png
  38. BIN
      IDE/Contents/Resources/Images/barlogo.png
  39. BIN
      IDE/Contents/Resources/Images/play_button.png
  40. BIN
      IDE/Contents/Resources/Images/stop_button.png
  41. BIN
      IDE/Contents/Resources/Images/welcome.png
  42. 0 10
      IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/.substance
  43. BIN
      IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/Resources/polycode_logo.png
  44. 4 0
      IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/Scripts/Main.lua
  45. 1 1
      IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/template.polyproject
  46. 0 10
      IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/.substance
  47. 0 0
      IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/Scripts/Main.lua
  48. 1 1
      IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/template.polyproject
  49. 1 1
      IDE/Contents/Resources/SyntaxThemes/monokai.xml
  50. BIN
      IDE/Contents/Resources/UIThemes/default/button.png
  51. BIN
      IDE/Contents/Resources/UIThemes/default/buttonFocused.png
  52. BIN
      IDE/Contents/Resources/UIThemes/default/checkbox_checked.png
  53. BIN
      IDE/Contents/Resources/UIThemes/default/checkbox_unchecked.png
  54. BIN
      IDE/Contents/Resources/UIThemes/default/closeIcon.png
  55. BIN
      IDE/Contents/Resources/UIThemes/default/colorboxBg.png
  56. BIN
      IDE/Contents/Resources/UIThemes/default/colorboxFrame.png
  57. BIN
      IDE/Contents/Resources/UIThemes/default/combobox_bg.png
  58. BIN
      IDE/Contents/Resources/UIThemes/default/combobox_drop.png
  59. BIN
      IDE/Contents/Resources/UIThemes/default/hsliderBg.png
  60. BIN
      IDE/Contents/Resources/UIThemes/default/hsliderHandle.png
  61. BIN
      IDE/Contents/Resources/UIThemes/default/menu_bg.png
  62. BIN
      IDE/Contents/Resources/UIThemes/default/menu_selector.png
  63. BIN
      IDE/Contents/Resources/UIThemes/default/selector.png
  64. BIN
      IDE/Contents/Resources/UIThemes/default/textfield.png
  65. BIN
      IDE/Contents/Resources/UIThemes/default/textfield_multi.png
  66. 56 46
      IDE/Contents/Resources/UIThemes/default/theme.xml
  67. BIN
      IDE/Contents/Resources/UIThemes/default/treeBg.png
  68. BIN
      IDE/Contents/Resources/UIThemes/default/treeCellBg.png
  69. BIN
      IDE/Contents/Resources/UIThemes/default/windowBg.png
  70. 2 2
      IDE/Contents/Source/NewFileWindow.cpp
  71. 6 6
      IDE/Contents/Source/NewProjectWindow.cpp
  72. 4 4
      IDE/Contents/Source/PolycodeConsole.cpp
  73. 3 3
      IDE/Contents/Source/PolycodeFrame.cpp
  74. 4 3
      IDE/Contents/Source/PolycodeIDEApp.cpp
  75. 3 3
      IDE/Contents/Source/PolycodeProjectBrowser.cpp
  76. 35 29
      IDE/Contents/Source/PolycodeProjectEditor.cpp
  77. 12 12
      IDE/Contents/Source/PolycodeProps.cpp
  78. 27 27
      IDE/Contents/Source/PolycodeScreenEditor.cpp
  79. 11 10
      IDE/Contents/Source/PolycodeSpriteEditor.cpp
  80. 9 9
      IDE/Contents/Source/PolycodeTextEditor.cpp
  81. 1 1
      IDE/Contents/Source/ToolWindows.cpp
  82. 1 1
      Modules/Contents/UI/Include/PolyUIButton.h
  83. 2 0
      Modules/Contents/UI/Include/PolyUIMenu.h
  84. 5 0
      Modules/Contents/UI/Include/PolyUITextInput.h
  85. 2 2
      Modules/Contents/UI/Source/PolyUIButton.cpp
  86. 3 2
      Modules/Contents/UI/Source/PolyUICheckBox.cpp
  87. 6 2
      Modules/Contents/UI/Source/PolyUIComboBox.cpp
  88. 6 4
      Modules/Contents/UI/Source/PolyUIMenu.cpp
  89. 14 6
      Modules/Contents/UI/Source/PolyUITextInput.cpp
  90. 2 1
      Modules/Contents/UI/Source/PolyUITree.cpp
  91. 7 2
      Modules/Contents/UI/Source/PolyUIWindow.cpp
  92. 2 0
      Player/Contents/Include/PolycodePlayer.h
  93. BIN
      Player/Contents/Platform/Darwin/app_file_icon.icns
  94. BIN
      Player/Contents/Platform/Darwin/player_icon.icns
  95. 8 2
      Player/Contents/Source/PolycodePlayer.cpp
  96. 18 0
      Tools/Contents/polybuild/Source/polybuild.cpp

BIN
Assets/Icons/Icon_base.psd


BIN
Assets/Icons/app_file_icon.icns


BIN
Assets/Icons/app_file_icon.png


BIN
Assets/Icons/file_icon_base.psd


BIN
Assets/Icons/main_icon.icns


BIN
Assets/Icons/main_icon.png


BIN
Assets/Icons/player_icon.icns


BIN
Assets/Icons/player_icon.png


BIN
Assets/Icons/polycode_project.icns


BIN
Assets/Icons/polycode_project.png


BIN
Assets/UIThemes.pak


BIN
Assets/UIThemes/default/button.png


BIN
Assets/UIThemes/default/buttonFocused.png


BIN
Assets/UIThemes/default/checkbox_checked.png


BIN
Assets/UIThemes/default/checkbox_unchecked.png


BIN
Assets/UIThemes/default/closeIcon.png


BIN
Assets/UIThemes/default/colorboxBg.png


BIN
Assets/UIThemes/default/colorboxFrame.png


BIN
Assets/UIThemes/default/combobox_bg.png


BIN
Assets/UIThemes/default/combobox_drop.png


BIN
Assets/UIThemes/default/hsliderBg.png


BIN
Assets/UIThemes/default/hsliderHandle.png


BIN
Assets/UIThemes/default/menu_bg.png


BIN
Assets/UIThemes/default/menu_selector.png


BIN
Assets/UIThemes/default/selector.png


BIN
Assets/UIThemes/default/textfield.png


BIN
Assets/UIThemes/default/textfield_multi.png


+ 57 - 47
Assets/UIThemes/default/theme.xml

@@ -1,20 +1,22 @@
 <?xml version="1.0"?>
 <PolyConfig>
 	<uiDefaultFontName>sans</uiDefaultFontName>
+	<uiDefaultFontColor>0xe4e0e3ab</uiDefaultFontColor>
 	<uiTextInputFontName>sans</uiTextInputFontName>
 	<uiTextInputFontNameMultiLine>mono</uiTextInputFontNameMultiLine>
-	<uiDefaultFontSize>11</uiDefaultFontSize>
-	<uiTextInputFontSize>11</uiTextInputFontSize>
+	<uiDefaultFontSize>12</uiDefaultFontSize>
+	<uiTextInputFontSize>12</uiTextInputFontSize>
 	<uiTextInputFontSizeMultiline>13</uiTextInputFontSizeMultiline>	
 	<uiTreeArrowIconImage>UIThemes/default/arrowIcon.png</uiTreeArrowIconImage>
 	<uiTreeCellHeight>20</uiTreeCellHeight>
 	<uiTreeCellPadding>4</uiTreeCellPadding>
 	
 	<textBgSkin>UIThemes/default/textfield.png</textBgSkin>
-	<textBgSkinT>3</textBgSkinT>
-	<textBgSkinR>3</textBgSkinR>
-	<textBgSkinB>3</textBgSkinB>
-	<textBgSkinL>3</textBgSkinL>
+	<textBgSkinMultiline>UIThemes/default/textfield_multi.png</textBgSkinMultiline>
+	<textBgSkinT>9</textBgSkinT>
+	<textBgSkinR>9</textBgSkinR>
+	<textBgSkinB>9</textBgSkinB>
+	<textBgSkinL>9</textBgSkinL>
 	<textBgSkinPadding>5</textBgSkinPadding>
 	<textEditLineSpacing>14</textEditLineSpacing>
 	
@@ -24,7 +26,7 @@
 	<uiTreeCellSkinR>3</uiTreeCellSkinR>
 	<uiTreeCellSkinB>3</uiTreeCellSkinB>
 	<uiTreeCellSkinL>3</uiTreeCellSkinL>
-	
+	<uiTreeFontColor>0xe4e0e3c8</uiTreeFontColor>
 	<uiTreeCellSelectorSkin>UIThemes/default/selector.png</uiTreeCellSelectorSkin>
 	<uiTreeCellSelectorSkinPadding>4</uiTreeCellSelectorSkinPadding>
 	<uiTreeCellSelectorSkinT>4</uiTreeCellSelectorSkinT>
@@ -44,27 +46,31 @@
 
 	<uiButtonSkin>UIThemes/default/button.png</uiButtonSkin>
 	<uiButtonFocusedSkin>UIThemes/default/buttonFocused.png</uiButtonFocusedSkin>
-	<uiButtonFontSize>11</uiButtonFontSize>	
+	<uiButtonFontSize>12</uiButtonFontSize>	
+	<uiButtonFontColor>0xe4e0e3c8</uiButtonFontColor>
 	<uiButtonLabelOffsetX>0</uiButtonLabelOffsetX>
-	<uiButtonLabelOffsetY>0</uiButtonLabelOffsetY>	
-	<uiButtonSkinT>4</uiButtonSkinT>
-	<uiButtonSkinR>4</uiButtonSkinR>
-	<uiButtonSkinB>4</uiButtonSkinB>
-	<uiButtonSkinL>4</uiButtonSkinL>
+	<uiButtonLabelOffsetY>4</uiButtonLabelOffsetY>	
+	<uiButtonSkinT>12</uiButtonSkinT>
+	<uiButtonSkinR>12</uiButtonSkinR>
+	<uiButtonSkinB>12</uiButtonSkinB>
+	<uiButtonSkinL>12</uiButtonSkinL>
 
 	<uiWindowSkin>UIThemes/default/windowBg.png</uiWindowSkin>
-	<uiWindowSkinT>29</uiWindowSkinT>
-	<uiWindowSkinR>12</uiWindowSkinR>
-	<uiWindowSkinB>12</uiWindowSkinB>
-	<uiWindowSkinL>12</uiWindowSkinL>
+	<uiWindowSkinT>24</uiWindowSkinT>
+	<uiWindowSkinR>17</uiWindowSkinR>
+	<uiWindowSkinB>17</uiWindowSkinB>
+	<uiWindowSkinL>17</uiWindowSkinL>
 	<uiWindowSkinPadding>15</uiWindowSkinPadding>		
-	<uiWindowTitleFont>sans</uiWindowTitleFont>
-	<uiWindowTitleFontSize>12</uiWindowTitleFontSize>
+	<uiWindowTitleFont>mono</uiWindowTitleFont>
+	<uiWindowFontColor>0xe4e0e3c8</uiWindowFontColor>	
+	<uiWindowTitleFontSize>14</uiWindowTitleFontSize>
 	<uiWindowTitleX>15</uiWindowTitleX>	
-	<uiWindowTitleY>7</uiWindowTitleY>		
+	<uiWindowTitleY>10</uiWindowTitleY>	
+	<uiWindowTitleBarHeight>25</uiWindowTitleBarHeight>
+	<uiWindowTitleBarOffset>5</uiWindowTitleBarOffset>	
 	<uiWindowCloseIcon>UIThemes/default/closeIcon.png</uiWindowCloseIcon>
 	<uiCloseIconX>11</uiCloseIconX>	
-	<uiCloseIconY>5</uiCloseIconY>		
+	<uiCloseIconY>11</uiCloseIconY>		
 
 	<uiScrollBgSkin>UIThemes/default/scrollBg.png</uiScrollBgSkin>
 	<uiScrollBgSkinPadding>1</uiScrollBgSkinPadding>
@@ -83,41 +89,45 @@
 	<uiTreeContainerScrollBarOffset>27</uiTreeContainerScrollBarOffset>
 	
 	<uiCheckBoxFont>sans</uiCheckBoxFont>
-	<uiCheckBoxFontSize>11</uiCheckBoxFontSize>	
+	<uiCheckBoxFontSize>12</uiCheckBoxFontSize>	
 	<uiCheckBoxCheckedImage>UIThemes/default/checkbox_checked.png</uiCheckBoxCheckedImage>
 	<uiCheckBoxUncheckedImage>UIThemes/default/checkbox_unchecked.png</uiCheckBoxUncheckedImage>
-	<uiCheckBoxLabelOffsetX>8</uiCheckBoxLabelOffsetX>
-	<uiCheckBoxLabelOffsetY>0</uiCheckBoxLabelOffsetY>
+	<uiCheckBoxLabelOffsetX>4</uiCheckBoxLabelOffsetX>
+	<uiCheckBoxLabelOffsetY>3</uiCheckBoxLabelOffsetY>
 		
 	<uiComboBoxFont>sans</uiComboBoxFont>
-	<uiComboBoxFontSize>11</uiComboBoxFontSize>
+	<uiComboBoxFontSize>12</uiComboBoxFontSize>
 	<uiComboBoxDropdownImage>UIThemes/default/combobox_drop.png</uiComboBoxDropdownImage>
 	<uiComboBoxBgImage>UIThemes/default/combobox_bg.png</uiComboBoxBgImage>
+	<uiComboBoxHeight>24</uiComboBoxHeight>
 	<uiComboBoxBgT>6</uiComboBoxBgT>
 	<uiComboBoxBgR>6</uiComboBoxBgR>
 	<uiComboBoxBgB>6</uiComboBoxBgB>
-	<uiComboBoxBgL>6</uiComboBoxBgL>				
+	<uiComboBoxBgL>6</uiComboBoxBgL>
+	<uiComboBoxDropX>6</uiComboBoxDropX>
+	<uiComboBoxDropY>5</uiComboBoxDropY>
 	<uiComboBoxTextOffsetX>7</uiComboBoxTextOffsetX>
-	<uiComboBoxTextOffsetY>0</uiComboBoxTextOffsetY>		
+	<uiComboBoxTextOffsetY>4</uiComboBoxTextOffsetY>		
 
 
 	<uiMenuFont>sans</uiMenuFont>
-	<uiMenuFontSize>11</uiMenuFontSize>
-	<uiMenuTextOffsetX>7</uiMenuTextOffsetX>
-	<uiMenuTextOffsetY>0</uiMenuTextOffsetY>		
-	<uiMenuPaddingX>4</uiMenuPaddingX>
-	<uiMenuPaddingY>8</uiMenuPaddingY>
+	<uiMenuFontSize>12</uiMenuFontSize>
+	<uiMenuTextOffsetX>10</uiMenuTextOffsetX>
+	<uiMenuTextOffsetY>-1</uiMenuTextOffsetY>		
+	<uiMenuPaddingX>7</uiMenuPaddingX>
+	<uiMenuPaddingY>20</uiMenuPaddingY>
+	<uiMenuItemHeight>22</uiMenuItemHeight>
 	<uiMenuBgImage>UIThemes/default/menu_bg.png</uiMenuBgImage>	
-	<uiMenuBgT>8</uiMenuBgT>
-	<uiMenuBgR>8</uiMenuBgR>
-	<uiMenuBgB>13</uiMenuBgB>
-	<uiMenuBgL>8</uiMenuBgL>			
+	<uiMenuBgT>25</uiMenuBgT>
+	<uiMenuBgR>18</uiMenuBgR>
+	<uiMenuBgB>22</uiMenuBgB>
+	<uiMenuBgL>18</uiMenuBgL>			
 	<uiMenuSelectorBgImage>UIThemes/default/menu_selector.png</uiMenuSelectorBgImage>	
-	<uiMenuSelectorBgT>3</uiMenuSelectorBgT>
-	<uiMenuSelectorBgR>3</uiMenuSelectorBgR>
-	<uiMenuSelectorBgB>3</uiMenuSelectorBgB>
-	<uiMenuSelectorBgL>3</uiMenuSelectorBgL>
-	
+	<uiMenuSelectorBgT>0</uiMenuSelectorBgT>
+	<uiMenuSelectorBgR>0</uiMenuSelectorBgR>
+	<uiMenuSelectorBgB>0</uiMenuSelectorBgB>
+	<uiMenuSelectorBgL>0</uiMenuSelectorBgL>
+	<uiMenuSelectorPadding>2</uiMenuSelectorPadding>
 
 	<uiColorBoxFrameImage>UIThemes/default/colorboxFrame.png</uiColorBoxFrameImage>
 	<uiColorBoxFrameImageT>7</uiColorBoxFrameImageT>
@@ -125,7 +135,7 @@
 	<uiColorBoxFrameImageB>7</uiColorBoxFrameImageB>
 	<uiColorBoxFrameImageL>7</uiColorBoxFrameImageL>					
 	<uiColorBoxBgImage>UIThemes/default/colorboxBg.png</uiColorBoxBgImage>
-	<uiColorBoxFrameInset>2</uiColorBoxFrameInset>
+	<uiColorBoxFrameInset>4</uiColorBoxFrameInset>
 
 	<uiColorPickerMainBg>UIThemes/default/colorPickerMainBg.png</uiColorPickerMainBg>
 	<uiColorPickerMainFrame>UIThemes/default/colorPickerMainFrame.png</uiColorPickerMainFrame>
@@ -135,10 +145,10 @@
 
 	<uiHSliderGrip>UIThemes/default/hsliderHandle.png</uiHSliderGrip>
 	<uiHSliderBg>UIThemes/default/hsliderBg.png</uiHSliderBg>
-	<uiHSliderBgHeight>6</uiHSliderBgHeight>
-	<uiHSliderBgT>2</uiHSliderBgT>
-	<uiHSliderBgR>4</uiHSliderBgR>
-	<uiHSliderBgB>2</uiHSliderBgB>
-	<uiHSliderBgL>4</uiHSliderBgL>
+	<uiHSliderBgHeight>10</uiHSliderBgHeight>
+	<uiHSliderBgT>5</uiHSliderBgT>
+	<uiHSliderBgR>6</uiHSliderBgR>
+	<uiHSliderBgB>5</uiHSliderBgB>
+	<uiHSliderBgL>6</uiHSliderBgL>
 
 </PolyConfig>

BIN
Assets/UIThemes/default/treeBg.png


BIN
Assets/UIThemes/default/treeCellBg.png


BIN
Assets/UIThemes/default/windowBg.png


+ 11 - 10
Core/Contents/Include/PolyColor.h

@@ -32,6 +32,16 @@ namespace Polycode {
 	class _PolyExport Color : public PolyBase {
 		public:
 
+	
+			/**
+			* Create from 0-1 floating point data.
+			* @param r Red value 0-1.
+			* @param g Green value 0-1
+			* @param b Blue value 0-1
+			* @param a Alpha value 0-1									
+			*/														
+			Color(Number r,Number g, Number b, Number a);
+			
 			/**
 			* Default constructor.
 			*/						
@@ -45,16 +55,7 @@ namespace Polycode {
 			* @param a Alpha value 0-255.									
 			*/									
 			Color(int r,int g, int b, int a);	
-			
-			/**
-			* Create from 0-1 floating point data.
-			* @param r Red value 0-1.
-			* @param g Green value 0-1
-			* @param b Blue value 0-1
-			* @param a Alpha value 0-1									
-			*/														
-			Color(Number r,Number g, Number b, Number a);
-			
+		
 			/**
 			* Create from another color.
 			* @param color The color to create from.

+ 51 - 106
Core/Contents/Source/PolyCocoaCore.mm

@@ -57,114 +57,16 @@ CocoaCore::CocoaCore(PolycodeView *view, int _xRes, int _yRes, bool fullScreen,
 	
 	userHomeDirectory = String([NSHomeDirectory() UTF8String]);
 	
-	NSOpenGLPixelFormatAttribute attrs[32];
-	
-	int atindx = 0;
-	attrs[atindx++] = NSOpenGLPFADoubleBuffer;
-	
-	attrs[atindx++] = NSOpenGLPFADepthSize;
-	attrs[atindx++] = 32;
-	
-	if(aaLevel > 0) {
-		attrs[atindx++] = NSOpenGLPFASampleBuffers;	
-		attrs[atindx++] = 1;	
-	
-		attrs[atindx++] = NSOpenGLPFASamples;	
-		attrs[atindx++] = aaLevel;	
-	
-		attrs[atindx++] = NSOpenGLPFAMultisample;	
-	}
-	
-	attrs[atindx++] = NSOpenGLPFANoRecovery;		
-
-	if(fullScreen) {
-		
-//		attrs[atindx++] = NSOpenGLPFAFullScreen;		
-//		attrs[atindx++] = NSOpenGLPFAScreenMask;	
-//		attrs[atindx++] = CGDisplayIDToOpenGLDisplayMask(kCGDirectMainDisplay);
-		
-	}
-	
-	attrs[atindx++] = NSOpenGLPFAAccelerated;			
-	
-	
-	attrs[atindx++] = nil;				
-/*	
-	NSOpenGLPixelFormatAttribute attrs[] =
-	{
-			NSOpenGLPFADoubleBuffer,	
-		NSOpenGLPFADepthSize, 16,
-//		NSOpenGLPFAFullScreen,
-//		NSOpenGLPFAScreenMask,
-//		CGDisplayIDToOpenGLDisplayMask(kCGDirectMainDisplay),
-		NSOpenGLPFASampleBuffers, 1,
-		NSOpenGLPFASamples,  aaLevel,
-		NSOpenGLPFANoRecovery,	
-//		NSOpenGLPFAWindow,
-		NSOpenGLPFAMultisample,
-//		NSOpenGLPFAAccelerated,
-//		NSOpenGLPFAAccumSize, 0,
-		nil
-	};	
-*/
-
-//	[view lockContext];
-	
-	[view setCore:this];	
-	NSOpenGLPixelFormat *format = [[NSOpenGLPixelFormat alloc] initWithAttributes:attrs];
-	
-	if(!format) {
-		NSLog(@"Error creating pixel format!\n");
-	}
-	
-	context = [[NSOpenGLContext alloc] initWithFormat: format shareContext:nil];
-	[format release];
-
-	if (context == nil) {
-        NSLog(@"Failed to create open gl context");
-	}	
-	
-	if(false) {
-
-//		[view enterFullScreenMode:[NSScreen mainScreen] withOptions:0];
-//		[view removeFromSuperview];
-//		[[view window] orderOut:nil];
-		
-//		CGDisplayCapture (kCGDirectMainDisplay ) ;			
-//		CGDisplaySwitchToMode (kCGDirectMainDisplay, CGDisplayBestModeForParameters (kCGDirectMainDisplay, 32, xRes, yRes, NULL) );				
-		
-		
-//		[context makeCurrentContext];		
-//		[context setFullScreen];
-//		[context flushBuffer];	
-//		CGDisplayCapture (kCGDirectMainDisplay ) ;		
-
-
-		
-//		[context clearDrawable];
-  //      [context release];		
-	} else {
-		[view clearGLContext];
-		[view setOpenGLContext:context];	
-		[context setView: (NSView*)view];					
-	}
-	
-	if(fullScreen) {
-	//	[view enterFullScreenMode:[NSScreen mainScreen] withOptions:0];	
-	}
-	
+	[view setCore:this];
 	
 	glView = view;
 	
-	initTime = mach_absolute_time();					
+	context = nil;
 	
-//	while(![view isContextReady]) {
+	initTime = mach_absolute_time();					
 		
-//	}
-	
 	renderer = new OpenGLRenderer();
-	services->setRenderer(renderer);	
-	//[view unlockContext];			
+	services->setRenderer(renderer);			
 	setVideoMode(xRes,yRes,fullScreen, vSync, aaLevel, anisotropyLevel);		
 
 	CoreServices::getInstance()->installModule(new GLSLShaderModule());	
@@ -193,11 +95,54 @@ String CocoaCore::getClipboardString() {
 	return [retString UTF8String];
 }
 
-void CocoaCore::setVideoMode(int xRes, int yRes, bool fullScreen, bool vSync, int aaLeve, int anisotropyLevel) {
+void CocoaCore::setVideoMode(int xRes, int yRes, bool fullScreen, bool vSync, int aaLevel, int anisotropyLevel) {
 	this->xRes = xRes;
 	this->yRes = yRes;
 	this->fullScreen = fullScreen;
 	this->aaLevel = aaLevel;
+	
+	NSOpenGLPixelFormatAttribute attrs[32];
+	
+	int atindx = 0;
+	attrs[atindx++] = NSOpenGLPFADoubleBuffer;
+	
+	attrs[atindx++] = NSOpenGLPFADepthSize;
+	attrs[atindx++] = 32;
+	
+	if(aaLevel > 0) {
+		attrs[atindx++] = NSOpenGLPFASampleBuffers;	
+		attrs[atindx++] = 1;	
+	
+		attrs[atindx++] = NSOpenGLPFASamples;	
+		attrs[atindx++] = aaLevel;	
+	
+		attrs[atindx++] = NSOpenGLPFAMultisample;	
+	}
+	
+	attrs[atindx++] = NSOpenGLPFANoRecovery;		
+	
+	attrs[atindx++] = NSOpenGLPFAAccelerated;			
+	attrs[atindx++] = nil;					
+	NSOpenGLPixelFormat *format = [[NSOpenGLPixelFormat alloc] initWithAttributes:attrs];		
+		
+	if(!format) {
+		NSLog(@"Error creating pixel format!\n");
+	}
+	
+	context = [[NSOpenGLContext alloc] initWithFormat: format shareContext:context];
+	[format release];
+
+	if (context == nil) {
+        NSLog(@"Failed to create open gl context");
+	}	
+	
+		
+	[glView clearGLContext];
+	[glView setOpenGLContext:context];	
+	[context setView: (NSView*)glView];					
+	
+		
+		
 	renderer->setAnisotropyAmount(anisotropyLevel);
 		
 	renderer->Resize(xRes, yRes);
@@ -243,13 +188,13 @@ void CocoaCore::setVideoMode(int xRes, int yRes, bool fullScreen, bool vSync, in
 	
 	[context setValues:&sync forParameter:NSOpenGLCPSwapInterval];	
 				
-	/*
+
 	if(aaLevel > 0) {
-		glEnable( GL_MULTISAMPLE_ARB );	
+		glEnable( GL_MULTISAMPLE_ARB );
 	} else {
 		glDisable( GL_MULTISAMPLE_ARB );			
 	}
-	*/
+	
 }
 
 void CocoaCore::openFileWithApplication(String file, String application) {

+ 7 - 7
Core/Contents/Source/PolyColor.cpp

@@ -47,10 +47,10 @@ Color::Color(unsigned int hex) {
 
 void Color::setColorHexRGB(unsigned int hex) {
 
-	int tr = (hex >> 24) & 0xFF;
-	int tb = (hex >> 16) & 0xFF;
+//	int tr = (hex >> 24) & 0xFF;
+	int tr = (hex >> 16) & 0xFF;
 	int tg = (hex >> 8) & 0xFF;
-//	int ta = (hex ) & 0xFF;
+	int tb = (hex ) & 0xFF;
 	
 	r = ((Number)tr)/255.0f;
 	g = ((Number)tg)/255.0f;
@@ -83,10 +83,10 @@ Color Color::blendColor(Color c2, int mode, Number amount, Color c3) {
 }
 
 void Color::setColorHex(unsigned int hex) {
-	int ta = (hex >> 24) & 0xFF;
-	int tb = (hex >> 16) & 0xFF;
-	int tg = (hex >> 8) & 0xFF;
-	int tr = (hex ) & 0xFF;
+	int tr = (hex >> 24) & 0xFF;
+	int tg = (hex >> 16) & 0xFF;
+	int tb = (hex >> 8) & 0xFF;
+	int ta = (hex ) & 0xFF;
 	
 	r = ((Number)tr)/255.0f;
 	g = ((Number)tg)/255.0f;

+ 1 - 1
IDE/Contents/Include/PolycodeTextEditor.h

@@ -52,7 +52,7 @@ class FindBar : public UIElement {
 		UITextInput *replaceInput;		
 		UIImageButton *closeButton;		
 		
-		UIImageButton *replaceAllButton;
+		UIButton *replaceAllButton;
 		
 	protected:
 		ScreenShape *barBg;

BIN
IDE/Contents/Resources/Fonts/Roboto-Thin.ttf


BIN
IDE/Contents/Resources/Images/barClose.png


BIN
IDE/Contents/Resources/Images/barlogo.png


BIN
IDE/Contents/Resources/Images/play_button.png


BIN
IDE/Contents/Resources/Images/stop_button.png


BIN
IDE/Contents/Resources/Images/welcome.png


+ 0 - 10
IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/.substance

@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<substanceRuntime>
-	<entryPoint>/Source/Classes.lua</entryPoint>
-	<backgroundColor red="0" green="0" blue="0"></backgroundColor>
-	<defaultWidth>640</defaultWidth>
-	<defaultHeight>480</defaultHeight>
-	<frameRate>60</frameRate>
-	<antiAliasingLevel>0</antiAliasingLevel>
-	<fullScreen>false</fullScreen>
-</substanceRuntime>

BIN
IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/Resources/polycode_logo.png


+ 4 - 0
IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/Scripts/Main.lua

@@ -0,0 +1,4 @@
+screen = Screen()
+
+image = ScreenImage("Resources/polycode_logo.png")
+screen:addChild(image)

+ 1 - 1
IDE/Contents/Resources/ProjectTemplates/Basic/2D Project/template.polyproject

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <PolycodeProject defaultWidth="640" defaultHeight="480" antiAliasingLevel="0">
 	<backgroundColor red="0.25" green="0.25" blue="0.25" />
-	<entryPoint>Source/Main.lua</entryPoint>
+	<entryPoint>Scripts/Main.lua</entryPoint>
 	<packedItems>
 		<item path="Resources" type="folder"/>
 	</packedItems>        	

+ 0 - 10
IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/.substance

@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<substanceRuntime>
-	<entryPoint>/Source/Classes.lua</entryPoint>
-	<backgroundColor red="0" green="0" blue="0"></backgroundColor>
-	<defaultWidth>640</defaultWidth>
-	<defaultHeight>480</defaultHeight>
-	<frameRate>60</frameRate>
-	<antiAliasingLevel>0</antiAliasingLevel>
-	<fullScreen>false</fullScreen>
-</substanceRuntime>

+ 0 - 0
IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/Scripts/Main.lua


+ 1 - 1
IDE/Contents/Resources/ProjectTemplates/Basic/Empty Project/template.polyproject

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <PolycodeProject defaultWidth="640" defaultHeight="480" antiAliasingLevel="0">
 	<backgroundColor red="0.25" green="0.25" blue="0.25" />
-	<entryPoint>Source/Main.lua</entryPoint>
+	<entryPoint>Scripts/Main.lua</entryPoint>
 </PolycodeProject>

+ 1 - 1
IDE/Contents/Resources/SyntaxThemes/monokai.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" ?>
 <syntaxTheme useStrongHinting="false">
-	<bgColor r="39" g="40" b="34"/>
+	<bgColor r="34" g="32" b="31"/>
 	<cursorColor r="255" g="255" b="255"/>
 	<selectionColor r="51" g="50" b="54"/>
 	<lineNumberColor r="70" g="60" b="50"/>

BIN
IDE/Contents/Resources/UIThemes/default/button.png


BIN
IDE/Contents/Resources/UIThemes/default/buttonFocused.png


BIN
IDE/Contents/Resources/UIThemes/default/checkbox_checked.png


BIN
IDE/Contents/Resources/UIThemes/default/checkbox_unchecked.png


BIN
IDE/Contents/Resources/UIThemes/default/closeIcon.png


BIN
IDE/Contents/Resources/UIThemes/default/colorboxBg.png


BIN
IDE/Contents/Resources/UIThemes/default/colorboxFrame.png


BIN
IDE/Contents/Resources/UIThemes/default/combobox_bg.png


BIN
IDE/Contents/Resources/UIThemes/default/combobox_drop.png


BIN
IDE/Contents/Resources/UIThemes/default/hsliderBg.png


BIN
IDE/Contents/Resources/UIThemes/default/hsliderHandle.png


BIN
IDE/Contents/Resources/UIThemes/default/menu_bg.png


BIN
IDE/Contents/Resources/UIThemes/default/menu_selector.png


BIN
IDE/Contents/Resources/UIThemes/default/selector.png


BIN
IDE/Contents/Resources/UIThemes/default/textfield.png


BIN
IDE/Contents/Resources/UIThemes/default/textfield_multi.png


+ 56 - 46
IDE/Contents/Resources/UIThemes/default/theme.xml

@@ -1,20 +1,22 @@
 <?xml version="1.0"?>
 <PolyConfig>
 	<uiDefaultFontName>sans</uiDefaultFontName>
+	<uiDefaultFontColor>0xe4e0e3ab</uiDefaultFontColor>
 	<uiTextInputFontName>sans</uiTextInputFontName>
 	<uiTextInputFontNameMultiLine>mono</uiTextInputFontNameMultiLine>
-	<uiDefaultFontSize>11</uiDefaultFontSize>
-	<uiTextInputFontSize>11</uiTextInputFontSize>
+	<uiDefaultFontSize>12</uiDefaultFontSize>
+	<uiTextInputFontSize>12</uiTextInputFontSize>
 	<uiTextInputFontSizeMultiline>13</uiTextInputFontSizeMultiline>	
 	<uiTreeArrowIconImage>arrowIcon.png</uiTreeArrowIconImage>
 	<uiTreeCellHeight>20</uiTreeCellHeight>
 	<uiTreeCellPadding>4</uiTreeCellPadding>
 	
 	<textBgSkin>textfield.png</textBgSkin>
-	<textBgSkinT>3</textBgSkinT>
-	<textBgSkinR>3</textBgSkinR>
-	<textBgSkinB>3</textBgSkinB>
-	<textBgSkinL>3</textBgSkinL>
+	<textBgSkinMultiline>textfield_multi.png</textBgSkinMultiline>
+	<textBgSkinT>9</textBgSkinT>
+	<textBgSkinR>9</textBgSkinR>
+	<textBgSkinB>9</textBgSkinB>
+	<textBgSkinL>9</textBgSkinL>
 	<textBgSkinPadding>5</textBgSkinPadding>
 	<textEditLineSpacing>14</textEditLineSpacing>
 	
@@ -24,7 +26,7 @@
 	<uiTreeCellSkinR>3</uiTreeCellSkinR>
 	<uiTreeCellSkinB>3</uiTreeCellSkinB>
 	<uiTreeCellSkinL>3</uiTreeCellSkinL>
-	
+	<uiTreeFontColor>0xe4e0e3c8</uiTreeFontColor>
 	<uiTreeCellSelectorSkin>selector.png</uiTreeCellSelectorSkin>
 	<uiTreeCellSelectorSkinPadding>4</uiTreeCellSelectorSkinPadding>
 	<uiTreeCellSelectorSkinT>4</uiTreeCellSelectorSkinT>
@@ -44,27 +46,31 @@
 
 	<uiButtonSkin>button.png</uiButtonSkin>
 	<uiButtonFocusedSkin>buttonFocused.png</uiButtonFocusedSkin>
-	<uiButtonFontSize>11</uiButtonFontSize>	
+	<uiButtonFontSize>12</uiButtonFontSize>	
+	<uiButtonFontColor>0xe4e0e3c8</uiButtonFontColor>
 	<uiButtonLabelOffsetX>0</uiButtonLabelOffsetX>
-	<uiButtonLabelOffsetY>0</uiButtonLabelOffsetY>	
-	<uiButtonSkinT>4</uiButtonSkinT>
-	<uiButtonSkinR>4</uiButtonSkinR>
-	<uiButtonSkinB>4</uiButtonSkinB>
-	<uiButtonSkinL>4</uiButtonSkinL>
+	<uiButtonLabelOffsetY>4</uiButtonLabelOffsetY>	
+	<uiButtonSkinT>12</uiButtonSkinT>
+	<uiButtonSkinR>12</uiButtonSkinR>
+	<uiButtonSkinB>12</uiButtonSkinB>
+	<uiButtonSkinL>12</uiButtonSkinL>
 
 	<uiWindowSkin>windowBg.png</uiWindowSkin>
-	<uiWindowSkinT>29</uiWindowSkinT>
-	<uiWindowSkinR>12</uiWindowSkinR>
-	<uiWindowSkinB>12</uiWindowSkinB>
-	<uiWindowSkinL>12</uiWindowSkinL>
+	<uiWindowSkinT>24</uiWindowSkinT>
+	<uiWindowSkinR>17</uiWindowSkinR>
+	<uiWindowSkinB>17</uiWindowSkinB>
+	<uiWindowSkinL>17</uiWindowSkinL>
 	<uiWindowSkinPadding>15</uiWindowSkinPadding>		
 	<uiWindowTitleFont>sans</uiWindowTitleFont>
-	<uiWindowTitleFontSize>12</uiWindowTitleFontSize>
+	<uiWindowFontColor>0xe4e0e3c8</uiWindowFontColor>	
+	<uiWindowTitleFontSize>14</uiWindowTitleFontSize>
 	<uiWindowTitleX>15</uiWindowTitleX>	
-	<uiWindowTitleY>7</uiWindowTitleY>		
+	<uiWindowTitleY>10</uiWindowTitleY>
+	<uiWindowTitleBarHeight>25</uiWindowTitleBarHeight>
+	<uiWindowTitleBarOffset>5</uiWindowTitleBarOffset>
 	<uiWindowCloseIcon>closeIcon.png</uiWindowCloseIcon>
 	<uiCloseIconX>11</uiCloseIconX>	
-	<uiCloseIconY>5</uiCloseIconY>		
+	<uiCloseIconY>11</uiCloseIconY>		
 
 	<uiScrollBgSkin>scrollBg.png</uiScrollBgSkin>
 	<uiScrollBgSkinPadding>1</uiScrollBgSkinPadding>
@@ -83,41 +89,45 @@
 	<uiTreeContainerScrollBarOffset>27</uiTreeContainerScrollBarOffset>
 	
 	<uiCheckBoxFont>sans</uiCheckBoxFont>
-	<uiCheckBoxFontSize>11</uiCheckBoxFontSize>	
+	<uiCheckBoxFontSize>12</uiCheckBoxFontSize>	
 	<uiCheckBoxCheckedImage>checkbox_checked.png</uiCheckBoxCheckedImage>
 	<uiCheckBoxUncheckedImage>checkbox_unchecked.png</uiCheckBoxUncheckedImage>
-	<uiCheckBoxLabelOffsetX>8</uiCheckBoxLabelOffsetX>
-	<uiCheckBoxLabelOffsetY>0</uiCheckBoxLabelOffsetY>
+	<uiCheckBoxLabelOffsetX>4</uiCheckBoxLabelOffsetX>
+	<uiCheckBoxLabelOffsetY>3</uiCheckBoxLabelOffsetY>
 		
 	<uiComboBoxFont>sans</uiComboBoxFont>
-	<uiComboBoxFontSize>11</uiComboBoxFontSize>
+	<uiComboBoxFontSize>12</uiComboBoxFontSize>
 	<uiComboBoxDropdownImage>combobox_drop.png</uiComboBoxDropdownImage>
 	<uiComboBoxBgImage>combobox_bg.png</uiComboBoxBgImage>
+	<uiComboBoxHeight>24</uiComboBoxHeight>
 	<uiComboBoxBgT>6</uiComboBoxBgT>
 	<uiComboBoxBgR>6</uiComboBoxBgR>
 	<uiComboBoxBgB>6</uiComboBoxBgB>
-	<uiComboBoxBgL>6</uiComboBoxBgL>				
+	<uiComboBoxBgL>6</uiComboBoxBgL>
+	<uiComboBoxDropX>6</uiComboBoxDropX>
+	<uiComboBoxDropY>5</uiComboBoxDropY>
 	<uiComboBoxTextOffsetX>7</uiComboBoxTextOffsetX>
-	<uiComboBoxTextOffsetY>0</uiComboBoxTextOffsetY>		
+	<uiComboBoxTextOffsetY>4</uiComboBoxTextOffsetY>		
 
 
 	<uiMenuFont>sans</uiMenuFont>
-	<uiMenuFontSize>11</uiMenuFontSize>
-	<uiMenuTextOffsetX>7</uiMenuTextOffsetX>
-	<uiMenuTextOffsetY>0</uiMenuTextOffsetY>		
-	<uiMenuPaddingX>4</uiMenuPaddingX>
-	<uiMenuPaddingY>8</uiMenuPaddingY>
+	<uiMenuFontSize>12</uiMenuFontSize>
+	<uiMenuTextOffsetX>10</uiMenuTextOffsetX>
+	<uiMenuTextOffsetY>-1</uiMenuTextOffsetY>		
+	<uiMenuPaddingX>7</uiMenuPaddingX>
+	<uiMenuPaddingY>20</uiMenuPaddingY>
+	<uiMenuItemHeight>22</uiMenuItemHeight>
 	<uiMenuBgImage>menu_bg.png</uiMenuBgImage>	
-	<uiMenuBgT>8</uiMenuBgT>
-	<uiMenuBgR>8</uiMenuBgR>
-	<uiMenuBgB>13</uiMenuBgB>
-	<uiMenuBgL>8</uiMenuBgL>			
+	<uiMenuBgT>25</uiMenuBgT>
+	<uiMenuBgR>18</uiMenuBgR>
+	<uiMenuBgB>22</uiMenuBgB>
+	<uiMenuBgL>18</uiMenuBgL>			
 	<uiMenuSelectorBgImage>menu_selector.png</uiMenuSelectorBgImage>	
-	<uiMenuSelectorBgT>3</uiMenuSelectorBgT>
-	<uiMenuSelectorBgR>3</uiMenuSelectorBgR>
-	<uiMenuSelectorBgB>3</uiMenuSelectorBgB>
-	<uiMenuSelectorBgL>3</uiMenuSelectorBgL>
-	
+	<uiMenuSelectorBgT>0</uiMenuSelectorBgT>
+	<uiMenuSelectorBgR>0</uiMenuSelectorBgR>
+	<uiMenuSelectorBgB>0</uiMenuSelectorBgB>
+	<uiMenuSelectorBgL>0</uiMenuSelectorBgL>
+	<uiMenuSelectorPadding>2</uiMenuSelectorPadding>
 
 	<uiColorBoxFrameImage>colorboxFrame.png</uiColorBoxFrameImage>
 	<uiColorBoxFrameImageT>7</uiColorBoxFrameImageT>
@@ -125,7 +135,7 @@
 	<uiColorBoxFrameImageB>7</uiColorBoxFrameImageB>
 	<uiColorBoxFrameImageL>7</uiColorBoxFrameImageL>					
 	<uiColorBoxBgImage>colorboxBg.png</uiColorBoxBgImage>
-	<uiColorBoxFrameInset>2</uiColorBoxFrameInset>
+	<uiColorBoxFrameInset>4</uiColorBoxFrameInset>
 
 	<uiColorPickerMainBg>colorPickerMainBg.png</uiColorPickerMainBg>
 	<uiColorPickerMainFrame>colorPickerMainFrame.png</uiColorPickerMainFrame>
@@ -135,10 +145,10 @@
 
 	<uiHSliderGrip>hsliderHandle.png</uiHSliderGrip>
 	<uiHSliderBg>hsliderBg.png</uiHSliderBg>
-	<uiHSliderBgHeight>6</uiHSliderBgHeight>
-	<uiHSliderBgT>2</uiHSliderBgT>
-	<uiHSliderBgR>4</uiHSliderBgR>
-	<uiHSliderBgB>2</uiHSliderBgB>
-	<uiHSliderBgL>4</uiHSliderBgL>
+	<uiHSliderBgHeight>10</uiHSliderBgHeight>
+	<uiHSliderBgT>5</uiHSliderBgT>
+	<uiHSliderBgR>6</uiHSliderBgR>
+	<uiHSliderBgB>5</uiHSliderBgB>
+	<uiHSliderBgL>6</uiHSliderBgL>
 
 </PolyConfig>

BIN
IDE/Contents/Resources/UIThemes/default/treeBg.png


BIN
IDE/Contents/Resources/UIThemes/default/treeCellBg.png


BIN
IDE/Contents/Resources/UIThemes/default/windowBg.png


+ 2 - 2
IDE/Contents/Source/NewFileWindow.cpp

@@ -57,11 +57,11 @@ NewFileWindow::NewFileWindow() : UIWindow(L"Create New File", 480, 280) {
 		}
 	}	
 	
-	ScreenLabel *label2 = new ScreenLabel(L"NEW FILE NAME (WITHOUT EXTENSION)", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label2 = new ScreenLabel(L"NEW FILE NAME (NO EXTENSION)", 18, "section", Label::ANTIALIAS_FULL);
 	label2->color.a = 0.4;
 	label2->getLabel()->setColorForRange(Color(),0, 12);
 	label2->getLabel()->setColorForRange(Color(0.6, 0.6, 0.6, 1.0),12, 40);
-	label2->setText("NEW FILE NAME (WITHOUT EXTENSION)");
+	label2->setText("NEW FILE NAME (NO EXTENSION)");
 		
 	addChild(label2);
 	label2->setPosition(padding+220, templateContainer->getPosition().y-5);			

+ 6 - 6
IDE/Contents/Source/NewProjectWindow.cpp

@@ -62,23 +62,23 @@ NewProjectWindow::NewProjectWindow() : UIWindow(L"Create New Project", 480, 280)
 		}
 	}
 	
-	ScreenLabel *label2 = new ScreenLabel(L"PROJECT NAME", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label2 = new ScreenLabel(L"PROJECT NAME", 18, "section", Label::ANTIALIAS_FULL);
 	label2->color.a = 0.4;
 	addChild(label2);
-	label2->setPosition(padding+220, templateContainer->getPosition().y-5);		
+	label2->setPosition(padding+220, templateContainer->getPosition().y-2);		
 
 	projectNameInput = new UITextInput(false, 500-padding-210-padding-padding, 12);	
 	addChild(projectNameInput);
-	projectNameInput->setPosition(label2->getPosition().x, label2->getPosition().y + 30);
+	projectNameInput->setPosition(label2->getPosition().x-6, label2->getPosition().y + 25);
 	
-	ScreenLabel *label3 = new ScreenLabel(L"PROJECT LOCATION", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label3 = new ScreenLabel(L"PROJECT LOCATION", 18, "section", Label::ANTIALIAS_FULL);
 	label3->color.a = 0.4;
 	addChild(label3);
-	label3->setPosition(padding+220, templateContainer->getPosition().y+60);		
+	label3->setPosition(padding+220, templateContainer->getPosition().y+65);		
 	
 	projectLocationInput = new UITextInput(false, 500-padding-210-padding-padding, 12);	
 	addChild(projectLocationInput);
-	projectLocationInput->setPosition(label3->getPosition().x, label3->getPosition().y+30);
+	projectLocationInput->setPosition(label3->getPosition().x-6, label3->getPosition().y+25);
 
 	
 	locationSelectButton = new UIButton(L"Choose...", 100);

+ 4 - 4
IDE/Contents/Source/PolycodeConsole.cpp

@@ -94,13 +94,13 @@ BackTraceWindow::BackTraceWindow() : UIElement() {
 
 	labelBg = new ScreenShape(ScreenShape::SHAPE_RECT, 20,30);
 	labelBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	labelBg->setColor(0.1, 0.1, 0.1, 1.0);
+	labelBg->setColorInt(34, 32, 31, 255);	
 	addChild(labelBg);
 	
-	ScreenLabel *label = new ScreenLabel("CRASH STACK", 22, "section");
-	label->color.a = 0.3;
+	ScreenLabel *label = new ScreenLabel("CRASH STACK", 18, "section");
+	label->color.a = 0.4;
 	addChild(label);
-	label->setPosition(5,0);
+	label->setPosition(5,3);
 	
 }	
 

+ 3 - 3
IDE/Contents/Source/PolycodeFrame.cpp

@@ -537,7 +537,7 @@ PolycodeFrame::PolycodeFrame() : ScreenEntity() {
 	projectBrowser->treeContainer->getRootNode()->addEventListener(this, UITreeEvent::DRAG_START_EVENT);
 	
 	topBarBg = new ScreenShape(ScreenShape::SHAPE_RECT, 2,2);
-	topBarBg->setColor(0,0,0,1);
+	topBarBg->setColorInt(21, 18, 17, 255);
 	topBarBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	addChild(topBarBg);
 	
@@ -547,11 +547,11 @@ PolycodeFrame::PolycodeFrame() : ScreenEntity() {
 	
 	playButton = new UIImageButton("Images/play_button.png");
 	addChild(playButton);
-	playButton->setPosition(10,8);
+	playButton->setPosition(10,4);
 
 	stopButton = new UIImageButton("Images/stop_button.png");
 	addChild(stopButton);
-	stopButton->setPosition(10,8);
+	stopButton->setPosition(10,4);
 
 	
 	resizer = new ScreenImage("Images/corner_resize.png");	

+ 4 - 3
IDE/Contents/Source/PolycodeIDEApp.cpp

@@ -31,7 +31,9 @@ SyntaxHighlightTheme *globalSyntaxTheme;
 PolycodeIDEApp::PolycodeIDEApp(PolycodeView *view) : EventDispatcher() {
 	core = new CocoaCore(view, 900,700,false,true, 0, 0,30);	
 	core->addEventListener(this, Core::EVENT_CORE_RESIZE);	
-	CoreServices::getInstance()->getRenderer()->setClearColor(0.2,0.2,0.2);
+//	CoreServices::getInstance()->getRenderer()->setClearColor(40.0/255.0,37.0/255.0,36.0/255.0);
+	CoreServices::getInstance()->getRenderer()->setClearColor(43.0/255.0,39.0/255.0,38.0/255.0);
+//	CoreServices::getInstance()->getRenderer()->setClearColor(228.0/255.0,227.0/255.0,224.0/255.0);
 	
 	CoreServices::getInstance()->getRenderer()->setTextureFilteringMode(Renderer::TEX_FILTERING_NEAREST);
 				
@@ -51,9 +53,8 @@ PolycodeIDEApp::PolycodeIDEApp(PolycodeView *view) : EventDispatcher() {
 	CoreServices::getInstance()->getResourceManager()->addArchive("UIThemes/default/");
 	CoreServices::getInstance()->getResourceManager()->addArchive("Images/");	
 
-	CoreServices::getInstance()->getFontManager()->registerFont("section", "Fonts/LeagueGothic-Regular.otf");	
+	CoreServices::getInstance()->getFontManager()->registerFont("section", "Fonts/Roboto-Thin.ttf");
 
-	CoreServices::getInstance()->getFontManager()->registerFont("editor_font", "Fonts/Inconsolata.otf");
 
 //	CoreServices::getInstance()->getRenderer()->setTextureFilteringMode(Renderer::TEX_FILTERING_LINEAR);
 	CoreServices::getInstance()->getRenderer()->setTextureFilteringMode(Renderer::TEX_FILTERING_NEAREST);

+ 3 - 3
IDE/Contents/Source/PolycodeProjectBrowser.cpp

@@ -29,12 +29,12 @@ PolycodeProjectBrowser::PolycodeProjectBrowser() : UIElement() {
 	headerBg = new ScreenShape(ScreenShape::SHAPE_RECT,10,10);
 	addChild(headerBg);
 	headerBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	headerBg->setColor(0.1, 0.1, 0.1, 1.0);
+	headerBg->setColorInt(34, 32, 31, 255);
 	
-	ScreenLabel *label = new ScreenLabel("PROJECT BROWSER", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label = new ScreenLabel("PROJECT BROWSER", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	addChild(label);
-	label->setPosition(10, 0);
+	label->setPosition(10, 3);
 
 
 	treeContainer = new UITreeContainer("boxIcon.png", L"Projects", 200, 555);

+ 35 - 29
IDE/Contents/Source/PolycodeProjectEditor.cpp

@@ -97,14 +97,12 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	headerBg = new ScreenShape(ScreenShape::SHAPE_RECT,10,10);
 	addChild(headerBg);
 	headerBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	headerBg->setColor(0.1, 0.1, 0.1, 1.0);
+	headerBg->setColorInt(34, 32, 31, 255);
 	
-	ScreenLabel *label = new ScreenLabel("PROJECT SETTINGS", 22, "section", Label::ANTIALIAS_FULL);
-	label->color.a = 0.4;
+	ScreenLabel *label = new ScreenLabel("PROJECT SETTINGS", 18, "section", Label::ANTIALIAS_FULL);
+	label->color.a = 0.4;	
 	addChild(label);
-	label->setPosition(10, 0);
-
-
+	label->setPosition(10, 3);
 
 	moduleSettingsWindow = new UIElement();
 	moduleSettingsWindow->setPosition(350,10);
@@ -113,7 +111,7 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	
 	Number lastYPos = 40;
 
-	label = new ScreenLabel("PROJECT MODULES", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("PROJECT MODULES", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	moduleSettingsWindow->addChild(label);
 	label->setPosition(0, lastYPos);
@@ -136,7 +134,7 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	
 	lastYPos += 20;
 
-	label = new ScreenLabel("PROJECT FONTS", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("PROJECT FONTS", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	moduleSettingsWindow->addChild(label);
 	label->setPosition(0, lastYPos);
@@ -155,54 +153,59 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	mainSettingsWindow->setPosition(0,10);
 	addChild(mainSettingsWindow);
 	
-	ScreenLabel *label2 = new ScreenLabel(L"DEFAULT VIDEO OPTIONS", 22, "section", Label::ANTIALIAS_FULL);	
+	ScreenLabel *label2 = new ScreenLabel(L"DEFAULT VIDEO OPTIONS", 18, "section", Label::ANTIALIAS_FULL);	
 	label2->setColor(1.0, 1.0, 1.0, 0.4);
 	mainSettingsWindow->addChild(label2);
 	label2->setPosition(padding, 40);		
 
 		
-	label2 = new ScreenLabel(L"Width:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2 = new ScreenLabel(L"Width", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding, 80);		
+	label2->setPosition(padding + 6, 80);		
 	
 	defaultWidthInput = new UITextInput(false, 60, 12);	
 	mainSettingsWindow->addChild(defaultWidthInput);
-	defaultWidthInput->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	defaultWidthInput->setPosition(label2->getPosition().x-6, label2->getPosition().y+18);
 	defaultWidthInput->setNumberOnly(true);
 
-	label2 = new ScreenLabel(L"Height:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2 = new ScreenLabel(L"Height", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding + 80, 80);		
+	label2->setPosition(padding + 80 + 6, 80);		
 	
 	defaultHeightInput = new UITextInput(false, 60, 12);	
 	mainSettingsWindow->addChild(defaultHeightInput);
-	defaultHeightInput->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	defaultHeightInput->setPosition(label2->getPosition().x-6, label2->getPosition().y+18);
 	defaultHeightInput->setNumberOnly(true);
 	
-	label2 = new ScreenLabel(L"Anti-aliasing:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2 = new ScreenLabel(L"Anti-aliasing", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding + 160, 80);		
+	label2->setPosition(padding + 160 + 6, 80);		
 	
 	aaLevelComboBox = new UIComboBox(globalMenu, 120);		
 	aaLevelComboBox->addComboItem("No AA");
 	aaLevelComboBox->addComboItem("2x MSAA");
 	aaLevelComboBox->addComboItem("4x MSAA");
 	aaLevelComboBox->addComboItem("6x MSAA");			
-	aaLevelComboBox->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	aaLevelComboBox->setPosition(label2->getPosition().x-6, label2->getPosition().y+18);
 
 	label2 = new ScreenLabel(L"Texture filtering mode:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding, defaultHeightInput->getPosition().y+30);		
+	label2->setPosition(padding + 6, defaultHeightInput->getPosition().y+30);		
 	
 	texFilteringComboBox = new UIComboBox(globalMenu, 280);		
 	texFilteringComboBox->addComboItem("Nearest Neighbor");
 	texFilteringComboBox->addComboItem("Linear");
-	texFilteringComboBox->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	texFilteringComboBox->setPosition(label2->getPosition().x - 6, label2->getPosition().y+18);
 	
 
 	label2 = new ScreenLabel(L"Anisotropic filtering:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);	
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding, texFilteringComboBox->getPosition().y+30);		
+	label2->setPosition(padding + 6, texFilteringComboBox->getPosition().y+30);		
 	
 	afLevelComboBox = new UIComboBox(globalMenu, 280);		
 	afLevelComboBox->addComboItem("No Anisotropic Filtering");
@@ -211,34 +214,36 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	afLevelComboBox->addComboItem("4x Anisotropic Filtering");
 	afLevelComboBox->addComboItem("8x Anisotropic Filtering");
 	afLevelComboBox->addComboItem("16x Anisotropic Filtering");			
-	afLevelComboBox->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	afLevelComboBox->setPosition(label2->getPosition().x-6, label2->getPosition().y+18);
 
-	label2 = new ScreenLabel(L"Framerate:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2 = new ScreenLabel(L"Framerate", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding, afLevelComboBox->getPosition().y+30);		
+	label2->setPosition(padding + 6, afLevelComboBox->getPosition().y+30);		
 	
 	framerateInput = new UITextInput(false, 60, 12);	
 	mainSettingsWindow->addChild(framerateInput);
-	framerateInput->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	framerateInput->setPosition(label2->getPosition().x-6, label2->getPosition().y+18);
 	framerateInput->setNumberOnly(true);
 
 	vSyncCheckBox = new UICheckBox("V-Sync", false);
 	vSyncCheckBox->setPosition(label2->getPosition().x + 80, label2->getPosition().y+18);
 	mainSettingsWindow->addChild(vSyncCheckBox);
 	
-	label2 = new ScreenLabel(L"STARTUP OPTIONS", 22, "section", Label::ANTIALIAS_FULL);	
+	label2 = new ScreenLabel(L"STARTUP OPTIONS", 18, "section", Label::ANTIALIAS_FULL);	
 	label2->setColor(1.0, 1.0, 1.0, 0.4);
 	mainSettingsWindow->addChild(label2);
 	label2->setPosition(padding, vSyncCheckBox->getPosition().y+vSyncCheckBox->getHeight()+20);		
 	
 	
-	label2 = new ScreenLabel(L"Entry point file:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2 = new ScreenLabel(L"Entry point file", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);	
 	mainSettingsWindow->addChild(label2);
-	label2->setPosition(padding, vSyncCheckBox->getPosition().y+70);		
+	label2->setPosition(padding + 6, vSyncCheckBox->getPosition().y+80);		
 	
 	entryPointInput = new UITextInput(false, 200, 12);	
 	mainSettingsWindow->addChild(entryPointInput);
-	entryPointInput->setPosition(label2->getPosition().x, label2->getPosition().y+18);
+	entryPointInput->setPosition(label2->getPosition().x - 6, label2->getPosition().y+18);
 
 
 	mainSettingsWindow->addChild(afLevelComboBox);			
@@ -246,6 +251,7 @@ PolycodeProjectEditor::PolycodeProjectEditor(PolycodeProjectManager *projectMana
 	mainSettingsWindow->addChild(texFilteringComboBox);	
 
 	label2 = new ScreenLabel(L"Background color:", fontSize, fontName, Label::ANTIALIAS_FULL);
+	label2->setColor(1.0, 1.0, 1.0, 0.5);
 	mainSettingsWindow->addChild(label2);
 	label2->setPosition(padding, entryPointInput->getPosition().y+entryPointInput->getHeight()+10);		
 

+ 12 - 12
IDE/Contents/Source/PolycodeProps.cpp

@@ -33,7 +33,7 @@ PropList::PropList(String caption) : UIElement() {
 
 	bg = new ScreenShape(ScreenShape::SHAPE_RECT, 10,10);
 	bg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	bg->setColor(0.18, 0.18, 0.18, 1.0);
+	bg->setColor(43.0/255.0,39.0/255.0,38.0/255.0, 1.0);
 	addChild(bg);
 	bg->blockMouseInput = true;
 	bg->processInputEvents = true;
@@ -42,13 +42,13 @@ PropList::PropList(String caption) : UIElement() {
 
 	bg2 = new ScreenShape(ScreenShape::SHAPE_RECT, 10,10);
 	bg2->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	bg2->setColor(0.1, 0.1, 0.1, 1.0);
+	bg2->setColorInt(34, 32, 31, 255);
 	addChild(bg2);
 
-	ScreenLabel *label = new ScreenLabel(caption, 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label = new ScreenLabel(caption, 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	addChild(label);
-	label->setPosition(10, 0);
+	label->setPosition(10, 3);
 
 	propContents = new ScreenEntity();
 	propContents->processInputEvents = true;
@@ -117,7 +117,7 @@ PropSheet::PropSheet(String caption, String type) : UIElement() {
 	
 	bg = new ScreenShape(ScreenShape::SHAPE_RECT, 30,30);
 	addChild(bg);
-	bg->setColor(0.14, 0.14, 0.14, 1.0);
+	bg->setColorInt(34, 32, 31, 255);
 	bg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	
 	ScreenLabel *label = new ScreenLabel(caption, 18, "section", Label::ANTIALIAS_FULL);
@@ -202,7 +202,7 @@ void PropSheet::addProp(PropProp *prop) {
 }
 
 PropProp::PropProp(String caption) : UIElement() {
-	label = new ScreenLabel(caption, 11);
+	label = new ScreenLabel(caption, 12);
 	label->color.a = 0.4;
 	label->setPosition(0, 5);
 	addChild(label);
@@ -210,7 +210,7 @@ PropProp::PropProp(String caption) : UIElement() {
 	propContents = new ScreenEntity();
 	propContents->processInputEvents = true;
 	addChild(propContents);
-	propContents->setPosition(90, 0);
+	propContents->setPosition(100, 0);
 	
 	setHeight(20);
 }
@@ -231,14 +231,14 @@ Vector2Prop::Vector2Prop(String caption) : PropProp(caption) {
 	propContents->addChild(label);
 	label->setPosition(60, 6);	
 
-	positionX = new UITextInput(false, 50, 10);
+	positionX = new UITextInput(false, 50, 12);
 	positionX->addEventListener(this, UIEvent::CHANGE_EVENT);
 	positionX->setText("0");
 	positionX->setNumberOnly(true);
 	propContents->addChild(positionX);
 	positionX->setPosition(0, 0);
 
-	positionY = new UITextInput(false, 50, 10);
+	positionY = new UITextInput(false, 50, 12);
 	positionY->setText("0");
 	positionY->addEventListener(this, UIEvent::CHANGE_EVENT);	
 	positionY->setNumberOnly(true);
@@ -272,7 +272,7 @@ Vector2Prop::~Vector2Prop() {
 
 StringProp::StringProp(String caption) : PropProp(caption) {
 
-	stringEntry = new UITextInput(false, 150, 10);
+	stringEntry = new UITextInput(false, 150, 12);
 	stringEntry->addEventListener(this, UIEvent::CHANGE_EVENT);
 	stringEntry->setText("");
 	propContents->addChild(stringEntry);
@@ -343,12 +343,12 @@ SliderProp::~SliderProp() {
 
 NumberProp::NumberProp(String caption) : PropProp(caption) {
 
-	numberEntry = new UITextInput(false, 50, 10);
+	numberEntry = new UITextInput(false, 50, 12);
 	numberEntry->addEventListener(this, UIEvent::CHANGE_EVENT);
 	numberEntry->setText("0");
 	numberEntry->setNumberOnly(true);
 	propContents->addChild(numberEntry);
-	numberEntry->setPosition(0, 0);
+	numberEntry->setPosition(0, 2);
 
 	setHeight(30);
 

+ 27 - 27
IDE/Contents/Source/PolycodeScreenEditor.cpp

@@ -73,19 +73,19 @@ EntityTreeView::EntityTreeView(Entity *rootEntity) : UIElement() {
 	bg = new ScreenShape(ScreenShape::SHAPE_RECT,10,10);
 	addChild(bg);
 	bg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	bg->setColor(0.18, 0.18, 0.18, 1.0);
+	bg->setColorInt(34, 32, 31, 255);
 	bg->blockMouseInput = true;
 	bg->processInputEvents = true;
 	
 	headerBg = new ScreenShape(ScreenShape::SHAPE_RECT,10,10);
 	addChild(headerBg);
 	headerBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	headerBg->setColor(0.1, 0.1, 0.1, 1.0);
+	headerBg->setColorInt(34, 32, 31, 255);
 	
-	ScreenLabel *label = new ScreenLabel("TREE VIEW", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label = new ScreenLabel("TREE VIEW", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	addChild(label);
-	label->setPosition(10, 0);
+	label->setPosition(10, 3);
 	
 	treeContainer = new UITreeContainer("Images/entity_icon.png", L"Layers", 200, 555);
 	treeContainer->getRootNode()->toggleCollapsed();
@@ -435,7 +435,7 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 	viewOptions->blockMouseInput = true;
 			
 	viewOptionsBg = new ScreenShape(ScreenShape::SHAPE_RECT, 20,20);
-	viewOptionsBg->setColor(0.1, 0.1, 0.1, 1.0);
+	viewOptionsBg->setColorInt(34, 32, 31, 255);
 	viewOptionsBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	viewOptions->addChild(viewOptionsBg);
 	
@@ -443,36 +443,36 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 	viewOptionsBg->processInputEvents = true;
 	
 
-	ScreenLabel *label = new ScreenLabel("GRID", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label = new ScreenLabel("GRID", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;		
 	viewOptions->addChild(label);
-	label->setPosition(10, 0);
+	label->setPosition(10, 3);
 	
 	gridSizeInput = new UITextInput(false, 40, 12);
 	gridSizeInput->setText("16");
 	viewOptions->addChild(gridSizeInput);
-	gridSizeInput->setPosition(50, 4);
+	gridSizeInput->setPosition(60, 4);
 	gridSizeInput->addEventListener(this, UIEvent::CHANGE_EVENT);
 	
 	gridCheckBox = new UICheckBox("On", true);
 	gridCheckBox->addEventListener(this, UIEvent::CHANGE_EVENT);
 	viewOptions->addChild(gridCheckBox);
-	gridCheckBox->setPosition(100, 5);
+	gridCheckBox->setPosition(115, 5);
 
-	label = new ScreenLabel("SNAP", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("SNAP", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;		
 	viewOptions->addChild(label);
-	label->setPosition(170, 0);
+	label->setPosition(180, 3);
 
 	pixelSnapBox = new UICheckBox("Pixel", true);
 	pixelSnapBox->addEventListener(this, UIEvent::CHANGE_EVENT);	
 	viewOptions->addChild(pixelSnapBox);
-	pixelSnapBox->setPosition(210, 5);
+	pixelSnapBox->setPosition(230, 5);
 
 	gridSnapBox = new UICheckBox("Grid", true);
 	gridSnapBox->addEventListener(this, UIEvent::CHANGE_EVENT);
 	viewOptions->addChild(gridSnapBox);
-	gridSnapBox->setPosition(280, 5);
+	gridSnapBox->setPosition(290, 5);
 	gridSnapBox->setChecked(false);
 	
 		
@@ -482,27 +482,27 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 	properties->blockMouseInput = true;
 			
 	propertiesBg = new ScreenShape(ScreenShape::SHAPE_RECT, 20,20);
-	propertiesBg->setColor(0.1, 0.1, 0.1, 1.0);
+	propertiesBg->setColorInt(34, 32, 31, 255);
 	propertiesBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	properties->addChild(propertiesBg);
 	propertiesBg->blockMouseInput = true;
 	propertiesBg->processInputEvents = true;
 	
-	label = new ScreenLabel("SCREEN RATIO", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("SCREEN RATIO", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;		
 	properties->addChild(label);
-	label->setPosition(10, 0);
+	label->setPosition(10, 3);
 	
 	scaleInput = new UITextInput(false, 70, 12);
 	scaleInput->setText("1.0");
 	properties->addChild(scaleInput);
-	scaleInput->setPosition(110, 4);
+	scaleInput->setPosition(140, 4);
 	scaleInput->addEventListener(this, UIEvent::CHANGE_EVENT);
 	
-	label = new ScreenLabel("PREVIEW ASPECT", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("PREVIEW ASPECT", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;		
 	properties->addChild(label);
-	label->setPosition(200, 0);
+	label->setPosition(230, 3);
 	
 	aspectComboBox = new UIComboBox(globalMenu, 80);
 	aspectComboBox->addComboItem("4:3");
@@ -521,12 +521,12 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 							
 	aspectComboBox->setSelectedIndex(0);
 	properties->addChild(aspectComboBox);
-	aspectComboBox->setPosition(310, 2);
+	aspectComboBox->setPosition(380, 2);
 			
-	label = new ScreenLabel("ZOOM", 22, "section", Label::ANTIALIAS_FULL);
+	label = new ScreenLabel("ZOOM", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;		
 	properties->addChild(label);
-	label->setPosition(410, 0);
+	label->setPosition(470, 3);
 			
 	zoomComboBox = new UIComboBox(globalMenu, 80);
 	zoomComboBox->addComboItem("8:1");
@@ -550,7 +550,7 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 	
 	zoomComboBox->addEventListener(this, UIEvent::CHANGE_EVENT);	
 	properties->addChild(zoomComboBox);
-	zoomComboBox->setPosition(450, 2);
+	zoomComboBox->setPosition(530, 2);
 			
 	toolPalette = new ScreenEntity();
 	toolPalette->setPosition(0, 30);
@@ -560,7 +560,7 @@ PolycodeScreenEditorMain::PolycodeScreenEditorMain() {
 	
 	toolPaletteBg = new ScreenShape(ScreenShape::SHAPE_RECT, 80, 20);
 	toolPaletteBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	toolPaletteBg->setColor(0.16, 0.16, 0.16, 1.0);
+	toolPaletteBg->setColorInt(34, 32, 31, 255);
 	toolPalette->addChild(toolPaletteBg);
 	toolPaletteBg->processInputEvents = true;
 	toolPaletteBg->blockMouseInput = true;
@@ -1971,10 +1971,10 @@ void PolycodeScreenEditorMain::setMode(int newMode) {
 void PolycodeScreenEditorMain::Resize(Number width, Number height) {
 
 
-	viewOptionsBg->setShapeSize(width, 30);
+	viewOptionsBg->setShapeSize(width+1, 30);
 	viewOptions->setPosition(0, height-30);
 
-	propertiesBg->setShapeSize(width, 30);
+	propertiesBg->setShapeSize(width+1, 30);
 	
 	toolPaletteBg->setShapeSize(100,height-60);
 			
@@ -2006,7 +2006,7 @@ void PolycodeScreenEditorMain::handleDroppedFile(OSFileEntry file, Number x, Num
 
 PolycodeScreenEditor::PolycodeScreenEditor() : PolycodeEditor(true){
 
-	mainSizer = new UIHSizer(100,100,280,false);
+	mainSizer = new UIHSizer(100,100,300,false);
 	addChild(mainSizer);	
 
 	editorMain = new PolycodeScreenEditorMain();

+ 11 - 10
IDE/Contents/Source/PolycodeSpriteEditor.cpp

@@ -37,19 +37,19 @@ SpriteAnimationEntry::SpriteAnimationEntry(SpriteAnimation *animation) : UIEleme
 	removeButton->addEventListener(this, UIEvent::CLICK_EVENT);
 	addChild(removeButton);
 
-	nameInput = new UITextInput(false, 90, 23);
+	nameInput = new UITextInput(false, 82, 12);
 	nameInput->setText(animation->name);
 	nameInput->setPosition(20, 0);
 	nameInput->addEventListener(this, UIEvent::CHANGE_EVENT);
 	addChild(nameInput);
 
-	framesInput = new UITextInput(false, 150, 23);
+	framesInput = new UITextInput(false, 142, 12);
 	framesInput->setText(animation->frames);
 	framesInput->setPosition(115, 0);
 	framesInput->addEventListener(this, UIEvent::CHANGE_EVENT);
 	addChild(framesInput);
 
-	speedInput = new UITextInput(false, 50, 23);
+	speedInput = new UITextInput(false, 42, 12);
 	speedInput->setText(String::NumberToString(animation->speed));
 	speedInput->setPosition(270, 0);
 	speedInput->addEventListener(this, UIEvent::CHANGE_EVENT);
@@ -99,7 +99,7 @@ PolycodeSpriteEditor::PolycodeSpriteEditor() : PolycodeEditor(true){
 	headerBg = new ScreenShape(ScreenShape::SHAPE_RECT,10,10);
 	addChild(headerBg);
 	headerBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	headerBg->setColor(0.1, 0.1, 0.1, 1.0);
+	headerBg->setColorInt(34, 32, 31, 255);
 	
 
 	propList = new PropList("SPRITE EDITOR");
@@ -110,25 +110,26 @@ PolycodeSpriteEditor::PolycodeSpriteEditor() : PolycodeEditor(true){
 	propList->addPropSheet(baseProps);
 	
 	textureProp = new TextureProp("Base image");
-	textureProp->addEventListener(this, Event::CHANGE_EVENT);
 	baseProps->addProp(textureProp);
 
 	widthProp = new NumberProp("Frame width");
-	widthProp->addEventListener(this, Event::CHANGE_EVENT);	
 	widthProp->set(32);
 	baseProps->addProp(widthProp);	
 
 	heightProp = new NumberProp("Frame height");
 	heightProp->set(32);	
-	heightProp->addEventListener(this, Event::CHANGE_EVENT);		
 	baseProps->addProp(heightProp);	
 	
+	widthProp->addEventListener(this, Event::CHANGE_EVENT);	
+	textureProp->addEventListener(this, Event::CHANGE_EVENT);
+	heightProp->addEventListener(this, Event::CHANGE_EVENT);		
+			
 	baseProps->propHeight = 180;
 	
-	ScreenLabel *label = new ScreenLabel("PREVIEW", 22, "section", Label::ANTIALIAS_FULL);
+	ScreenLabel *label = new ScreenLabel("PREVIEW", 18, "section", Label::ANTIALIAS_FULL);
 	label->color.a = 0.4;
 	addChild(label);
-	label->setPosition(390, 40);
+	label->setPosition(390, 36);
 			
 				
 	PropSheet *animationProps = new PropSheet("ANIMATIONS", "");
@@ -147,7 +148,7 @@ PolycodeSpriteEditor::PolycodeSpriteEditor() : PolycodeEditor(true){
 	
 	zoomBox = new UIComboBox(globalMenu, 100);
 	addChild(zoomBox);
-	zoomBox->setPosition(480, 36);
+	zoomBox->setPosition(490, 37);
 	zoomBox->addEventListener(this, UIEvent::CHANGE_EVENT);
 	
 	zoomBox->addComboItem("No Zoom");

+ 9 - 9
IDE/Contents/Source/PolycodeTextEditor.cpp

@@ -417,19 +417,19 @@ void PolycodeTextEditor::Resize(int x, int y) {
 FindBar::FindBar() : UIElement() {
 	barBg = new ScreenShape(ScreenShape::SHAPE_RECT, 30,30);
 	barBg->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
-	barBg->setColorInt(255, 222, 0, 255);
+	barBg->setColorInt(24, 22, 21, 255);
 	addChild(barBg);
 	this->height = 30;
 	
-	ScreenLabel *findLabel = new ScreenLabel("FIND", 22, "section");
+	ScreenLabel *findLabel = new ScreenLabel("FIND", 18, "section");
 	addChild(findLabel);
-	findLabel->setColor(0.0, 0.0, 0.0, 0.3);
-	findLabel->setPosition(10,6);
+	findLabel->setColor(1.0, 1.0, 1.0, 0.6);
+	findLabel->setPosition(10,3);
 
-	ScreenLabel *replaceLabel = new ScreenLabel("REPLACE", 22, "section");
+	ScreenLabel *replaceLabel = new ScreenLabel("REPLACE", 18, "section");
 	addChild(replaceLabel);
-	replaceLabel->setColor(0.0, 0.0, 0.0, 0.3);
-	replaceLabel->setPosition(200,6);
+	replaceLabel->setColor(1.0, 1.0, 1.0, 0.6);
+	replaceLabel->setPosition(200,3);
 
 	processInputEvents = true;
 	
@@ -441,9 +441,9 @@ FindBar::FindBar() : UIElement() {
 	addChild(replaceInput);
 	replaceInput->setPosition(280, 4);
 	
-	replaceAllButton = new UIImageButton("Images/replaceAll.png");
+	replaceAllButton = new UIButton("Replace All", 100);
 	addChild(replaceAllButton);
-	replaceAllButton->setPosition(420, 5);
+	replaceAllButton->setPosition(420, 3);
 	
 	closeButton = new UIImageButton("Images/barClose.png");
 	addChild(closeButton);

+ 1 - 1
IDE/Contents/Source/ToolWindows.cpp

@@ -24,7 +24,7 @@
 
 TextInputPopup::TextInputPopup() : UIWindow(L"", 300, 80) {
 	
-	textInput = new UITextInput(false, 300, 12);	
+	textInput = new UITextInput(false, 290, 12);	
 	addChild(textInput);
 	textInput->setPosition(padding, 35);
 		

+ 1 - 1
Modules/Contents/UI/Include/PolyUIButton.h

@@ -33,7 +33,7 @@ namespace Polycode {
 
 	class _PolyExport UIButton : public UIElement {
 		public:
-			UIButton(String text, Number width, Number height = 28);
+			UIButton(String text, Number width, Number height = 23);
 			~UIButton();		
 			void handleEvent(Event *event);
 			

+ 2 - 0
Modules/Contents/UI/Include/PolyUIMenu.h

@@ -59,6 +59,8 @@ namespace Polycode {
 			Number menuItemHeight;
 			Number menuWidth;
 			
+			Number selectorPadding;
+			
 			Number nextItemHeight;
 			
 			int selectedOffset;

+ 5 - 0
Modules/Contents/UI/Include/PolyUITextInput.h

@@ -236,6 +236,11 @@ namespace Polycode {
 			Timer *blinkTimer;
 			UIBox *inputRect;
 			ScreenShape *blinkerRect;
+			
+			Number st;
+			Number sr;
+			Number sb;
+			Number sl;
 		
 			Number caretImagePosition;
 			

+ 2 - 2
Modules/Contents/UI/Source/PolyUIButton.cpp

@@ -66,10 +66,10 @@ UIButton::UIButton(String text, Number width, Number height) : UIElement() {
 	pressedDown = false;
 	
 	buttonLabel = new ScreenLabel(text, fontSize, fontName, Label::ANTIALIAS_FULL);
-	buttonLabel->positionAtBaseline = false;
+	buttonLabel->color.setColorHex(strtol(conf->getStringValue("Polycode", "uiButtonFontColor").c_str(), 0, 16));
 	addChild(buttonLabel);
 	labelXPos = floor((width-buttonLabel->getWidth())/2.0f) + labelOffsetX;
-	labelYPos = floor((height-(buttonLabel->getLabel()->getTextHeight()))/2.0f) + labelOffsetY;
+	labelYPos = labelOffsetY;
 	buttonLabel->setPosition(labelXPos,labelYPos);
 	
 	this->width = width;

+ 3 - 2
Modules/Contents/UI/Source/PolyUICheckBox.cpp

@@ -48,14 +48,15 @@ UICheckBox::UICheckBox(String caption, bool checked) : UIElement() {
 	buttonImageUnchecked->visible = !checked;
 	
 	captionLabel = new ScreenLabel(caption, fontSize, fontName, Label::ANTIALIAS_FULL);
-	captionLabel->positionAtBaseline = false;
 	
 	addChild(captionLabel);
-	captionLabel->setPosition(buttonImageChecked->getWidth() + checkboxTextOffsetX, (buttonImageChecked->getHeight()/2.0) - (captionLabel->getLabel()->getTextHeight()/2.0) + checkboxTextOffsetY);
+	captionLabel->setPosition(buttonImageChecked->getWidth() + checkboxTextOffsetX, checkboxTextOffsetY);
 	
 	addChild(buttonImageUnchecked);	
 	addChild(buttonImageChecked);
 	
+	captionLabel->color.setColorHex(strtol(conf->getStringValue("Polycode", "uiDefaultFontColor").c_str(), 0, 16));
+	
 	buttonImageUnchecked->addEventListener(this, InputEvent::EVENT_MOUSEOVER);
 	buttonImageUnchecked->addEventListener(this, InputEvent::EVENT_MOUSEOUT);
 	buttonImageUnchecked->addEventListener(this, InputEvent::EVENT_MOUSEUP);

+ 6 - 2
Modules/Contents/UI/Source/PolyUIComboBox.cpp

@@ -57,11 +57,14 @@ UIComboBox::UIComboBox(UIGlobalMenu *globalMenu, Number comboWidth) : UIElement(
 	
 	Number paddingX = conf->getNumericValue("Polycode", "uiComboBoxTextOffsetX");	
 	Number paddingY = conf->getNumericValue("Polycode", "uiComboBoxTextOffsetY");	
+
+	Number dropDownX = conf->getNumericValue("Polycode", "uiComboBoxDropX");
+	Number dropDownY = conf->getNumericValue("Polycode", "uiComboBoxDropY");
 		
 	dropDownImage = new ScreenImage(dropDownImageFile);
-	dropDownImage->setPosition(comboWidth - dropDownImage->getWidth(),0);
+	dropDownImage->setPosition(comboWidth - dropDownImage->getWidth() - dropDownX,dropDownY);
 	
-	this->comboHeight = dropDownImage->getHeight();
+	this->comboHeight = conf->getNumericValue("Polycode", "uiComboBoxHeight");
 	this->comboWidth = comboWidth;
 	nextItemHeight = 0;
 	
@@ -75,6 +78,7 @@ UIComboBox::UIComboBox(UIGlobalMenu *globalMenu, Number comboWidth) : UIElement(
 	selectedLabel->setPosition(paddingX, floor(((dropDownImage->getHeight()/2.0) - selectedLabel->getLabel()->getTextHeight()/2.0) + paddingY));
 	addChild(selectedLabel);
 	
+	selectedLabel->color.setColorHex(strtol(conf->getStringValue("Polycode", "uiDefaultFontColor").c_str(), 0, 16));
 	
 	String selectorBgImage = conf->getStringValue("Polycode", "uiComboBoxSelectorBgImage");	
 	

+ 6 - 4
Modules/Contents/UI/Source/PolyUIMenu.cpp

@@ -59,7 +59,7 @@ UIMenu::UIMenu(Number menuWidth) : UIElement() {
 
 	Config *conf = CoreServices::getInstance()->getConfig();	
 				
-	this->menuItemHeight = 20.0;	
+	this->menuItemHeight = conf->getNumericValue("Polycode", "uiMenuItemHeight");
 	this->menuWidth = menuWidth;
 	nextItemHeight = 0;
 			
@@ -86,7 +86,9 @@ UIMenu::UIMenu(Number menuWidth) : UIElement() {
 	
 	dropDownBox->blockMouseInput = true;
 	
-	selectorBox = new UIBox(selectorBgImage, st,sr,sb,sl, menuWidth-(paddingX*2.0), menuItemHeight);
+	selectorPadding = conf->getNumericValue("Polycode", "uiMenuSelectorPadding");
+	
+	selectorBox = new UIBox(selectorBgImage, st,sr,sb,sl, menuWidth - (paddingX * 2.0), menuItemHeight + (selectorPadding * 2.0));
 	dropDownBox->addChild(selectorBox);
 	selectorBox->blockMouseInput = true;
 	
@@ -160,11 +162,11 @@ void UIMenu::handleEvent(Event *event) {
 			case InputEvent::EVENT_MOUSEMOVE:
 			{
 				InputEvent *inputEvent = (InputEvent*) event;
-				selectedOffset = floor((inputEvent->getMousePosition().y-paddingY)/menuItemHeight);
+				selectedOffset = floor(((inputEvent->getMousePosition().y-selectorPadding)-paddingY)/menuItemHeight);
 					
 				if(selectedOffset >= 0 && selectedOffset < items.size()) {
 					selectorBox->visible = true;				
-					selectorBox->setPosition(paddingX,paddingY+(selectedOffset*menuItemHeight));
+					selectorBox->setPosition(paddingX,paddingY+(selectedOffset*menuItemHeight) - selectorPadding);
 				} else {
 					selectorBox->visible = false;
 				}

+ 14 - 6
Modules/Contents/UI/Source/PolyUITextInput.cpp

@@ -78,16 +78,23 @@ UITextInput::UITextInput(bool multiLine, Number width, Number height) : UIElemen
 	
 	lineSpacing = conf->getNumericValue("Polycode", "textEditLineSpacing");
 	
-	Number st = conf->getNumericValue("Polycode", "textBgSkinT");
-	Number sr = conf->getNumericValue("Polycode", "textBgSkinR");
-	Number sb = conf->getNumericValue("Polycode", "textBgSkinB");
-	Number sl = conf->getNumericValue("Polycode", "textBgSkinL");
+	st = conf->getNumericValue("Polycode", "textBgSkinT");
+	sr = conf->getNumericValue("Polycode", "textBgSkinR");
+	sb = conf->getNumericValue("Polycode", "textBgSkinB");
+	sl = conf->getNumericValue("Polycode", "textBgSkinL");
+
 	
 	padding = conf->getNumericValue("Polycode", "textBgSkinPadding");	
 	
-	inputRect = new UIBox(conf->getStringValue("Polycode", "textBgSkin"),
+	if(multiLine) {
+		inputRect = new UIBox(conf->getStringValue("Polycode", "textBgSkinMultiline"),
+						  st,sr,sb,sl,
+						  width+(padding*2), height+(padding*2));		
+	} else {
+		inputRect = new UIBox(conf->getStringValue("Polycode", "textBgSkin"),
 						  st,sr,sb,sl,
 						  width+(padding*2), height+(padding*2));	
+	}
 	
 	addChild(inputRect);		
 	
@@ -104,6 +111,7 @@ UITextInput::UITextInput(bool multiLine, Number width, Number height) : UIElemen
 	} else {
 		lineNumberBg = NULL;
 		lineNumberAnchor = NULL;
+		decoratorOffset = sl/2.0;
 	}
 
 	
@@ -1332,7 +1340,7 @@ void UITextInput::Update() {
 
 	if(!multiLine) {
 		Vector2 pos = getScreenPosition();
-		scissorBox.setRect(pos.x,pos.y, width, height);		
+		scissorBox.setRect(pos.x,pos.y, width+sr+sl, height+sb+st);
 	}
 
 	if(hasSelection) {

+ 2 - 1
Modules/Contents/UI/Source/PolyUITree.cpp

@@ -53,7 +53,8 @@ UITree::UITree(String icon, String text, Number treeWidth, Number treeOffset) :
 								size,
 								fontName,
 								Label::ANTIALIAS_FULL);
-
+	textLabel->color.setColorHex(strtol(conf->getStringValue("Polycode", "uiTreeFontColor").c_str(), 0, 16));
+	
 	bgBox = new ScreenShape(ScreenShape::SHAPE_RECT, treeWidth, cellHeight);	
 	bgBox->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	bgBox->setPosition(-treeOffset,0);	

+ 7 - 2
Modules/Contents/UI/Source/PolyUIWindow.cpp

@@ -59,7 +59,11 @@ UIWindow::UIWindow(String windowName, Number width, Number height) : ScreenEntit
 	
 	addChild(windowRect);
 	
-	titlebarRect = new ScreenShape(ScreenShape::SHAPE_RECT, width, st);
+	Number titleBarHeight = conf->getNumericValue("Polycode", "uiWindowTitleBarHeight");
+	Number titleBarOffset = conf->getNumericValue("Polycode", "uiWindowTitleBarOffset");
+		
+	titlebarRect = new ScreenShape(ScreenShape::SHAPE_RECT, width, titleBarHeight);
+	titlebarRect->setPosition(0, titleBarOffset);
 	titlebarRect->setColor(0,0,0,0);
 	titlebarRect->setPositionMode(ScreenEntity::POSITION_TOPLEFT);
 	titlebarRect->processInputEvents = true;
@@ -68,7 +72,8 @@ UIWindow::UIWindow(String windowName, Number width, Number height) : ScreenEntit
 	titleLabel = new ScreenLabel(windowName, fontSize, fontName, Label::ANTIALIAS_FULL);
 	titleLabel->setPosition(conf->getNumericValue("Polycode", "uiWindowTitleX"),conf->getNumericValue("Polycode", "uiWindowTitleY"));
 	addChild(titleLabel);
-	
+	titleLabel->color.setColorHex(strtol(conf->getStringValue("Polycode", "uiWindowFontColor").c_str(), 0, 16));
+		
 	closeBtn = new UIImageButton(conf->getStringValue("Polycode", "uiWindowCloseIcon"));
 	addChild(closeBtn);
 	closeIconX = conf->getNumericValue("Polycode", "uiCloseIconX");

+ 2 - 0
Player/Contents/Include/PolycodePlayer.h

@@ -124,6 +124,8 @@ public:
 	int xRes;
 	int yRes;
 	int aaLevel;
+	int anisotropyLevel;
+	bool vSync;
 	bool fullScreen;	
 	
 	int frameRate;

BIN
Player/Contents/Platform/Darwin/app_file_icon.icns


BIN
Player/Contents/Platform/Darwin/player_icon.icns


+ 8 - 2
Player/Contents/Source/PolycodePlayer.cpp

@@ -562,7 +562,13 @@ void PolycodePlayer::loadFile(const char *fileName) {
 		}		
 		if(configFile.root["antiAliasingLevel"]) {
 			aaLevel = configFile.root["antiAliasingLevel"]->intVal;
+		}
+		if(configFile.root["anisotropyLevel"]) {
+			anisotropyLevel = configFile.root["anisotropyLevel"]->intVal;
 		}		
+		if(configFile.root["vSync"]) {
+			vSync = configFile.root["vSync"]->boolVal;
+		}						
 		if(configFile.root["fullScreen"]) {
 			fullScreen = configFile.root["fullScreen"]->boolVal;
 		}				
@@ -689,7 +695,7 @@ void PolycodePlayer::loadFile(const char *fileName) {
 	
 	core->setUserPointer(this);
 	//core->addEventListener(this, Core::EVENT_CORE_RESIZE);
-	core->setVideoMode(xRes, yRes, fullScreen, false, 0, aaLevel);
+	core->setVideoMode(xRes, yRes, fullScreen, vSync, aaLevel, anisotropyLevel);
 	
 	if(textureFiltering == "nearest") {
 		CoreServices::getInstance()->getRenderer()->setTextureFilteringMode(Renderer::TEX_FILTERING_NEAREST);
@@ -864,7 +870,7 @@ void PolycodePlayer::handleEvent(Event *event) {
 
 bool PolycodePlayer::Update() {
 	if(L) {
-		lua_settop(L, 0);				
+		lua_settop(L, 0);
 		if(doCodeInject) {
 			printf("INJECTING CODE:[%s]\n", injectCodeString.c_str());
 			doCodeInject = false;			

+ 18 - 0
Tools/Contents/polybuild/Source/polybuild.cpp

@@ -256,6 +256,8 @@ int main(int argc, char **argv) {
 	int defaultHeight;
 	int frameRate = 60;
 	int antiAliasingLevel = 0;
+	int anisotropyLevel = 0;
+	bool vSync = false;
 	bool fullScreen = false;
 	float backgroundColorR = 0.2;
 	float backgroundColorG = 0.2;
@@ -303,6 +305,20 @@ int main(int argc, char **argv) {
 		antiAliasingLevel = configFile.root["antiAliasingLevel"]->intVal;
 	}
 
+	if(configFile.root["anisotropyLevel"]) {
+		printf("Anisotropy level: %d\n", configFile.root["anisotropyLevel"]->intVal);
+		anisotropyLevel = configFile.root["anisotropyLevel"]->intVal;
+	}
+	
+	if(configFile.root["vSync"]) {
+		vSync = configFile.root["vSync"]->boolVal;
+		if(vSync) {
+			printf("V-Sync: true\n");
+		} else {
+			printf("V-Sync: false\n");
+		}
+	}	
+
 	if(configFile.root["fullScreen"]) {
 		fullScreen = configFile.root["fullScreen"]->boolVal;
 		if(fullScreen) {
@@ -335,6 +351,8 @@ int main(int argc, char **argv) {
 	runInfo.root.addChild("defaultWidth", defaultWidth);
 	runInfo.root.addChild("frameRate", frameRate);
 	runInfo.root.addChild("antiAliasingLevel", antiAliasingLevel);
+	runInfo.root.addChild("anisotropyLevel", anisotropyLevel);
+	runInfo.root.addChild("vSync", vSync);	
 	runInfo.root.addChild("fullScreen", fullScreen);
 	runInfo.root.addChild("textureFiltering", String(textureFiltering));