kabron Member Licensed User Longtime User Oct 26, 2014 #1 Sorry, if I repeated the question, but I had not find similar. The question is: when I launch program form IDE(Release/Debug) everything is OK.(Left pic.) But if I run the same program as a .jar application, it losts all color settings(Right pic.). It happens on Win7 x64 while OK on Win8.1 x32. So, what is wrong and what to do?
Sorry, if I repeated the question, but I had not find similar. The question is: when I launch program form IDE(Release/Debug) everything is OK.(Left pic.) But if I run the same program as a .jar application, it losts all color settings(Right pic.). It happens on Win7 x64 while OK on Win8.1 x32. So, what is wrong and what to do?
Erel B4X founder Staff member Licensed User Longtime User Oct 26, 2014 #2 Can you upload your project (File - Export as zip)? Upvote 0
kabron Member Licensed User Longtime User Oct 26, 2014 #3 Thanks for answer, Erel Here it is Attachments Bundle.zip 4.2 KB · Views: 152 Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Oct 26, 2014 #4 It looks white here. Where is the code that changes the background to black? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Oct 26, 2014 #5 Ok. I see it. For some reason there is a difference between Java 7 and Java 8 with your layout. How did you set the colors? Upvote 0
Ok. I see it. For some reason there is a difference between Java 7 and Java 8 with your layout. How did you set the colors?
kabron Member Licensed User Longtime User Oct 26, 2014 #6 Color settings are in main.fxml and Start.fxml. I guess it's enough. BTW, I tryed to set colors in the code with no result. Upvote 0
Color settings are in main.fxml and Start.fxml. I guess it's enough. BTW, I tryed to set colors in the code with no result.
Erel B4X founder Staff member Licensed User Longtime User Oct 26, 2014 #7 You are adding a Canvas object that covers the whole form. You should set its color: B4X: Sub AppStart (Form1 As Form, Args() As String) MainForm = Form1 MainForm.RootPane.LoadLayout("Start") MainForm.BackColor = fx.Colors.Black Screen.Initialize("Screen") MainForm.RootPane.AddNode(Screen, 0, 0, MainForm.Width, MainForm.Height) Screen.DrawRect(0, 0, Screen.Width, Screen.Height, fx.Colors.Black, True, 0) Upvote 0
You are adding a Canvas object that covers the whole form. You should set its color: B4X: Sub AppStart (Form1 As Form, Args() As String) MainForm = Form1 MainForm.RootPane.LoadLayout("Start") MainForm.BackColor = fx.Colors.Black Screen.Initialize("Screen") MainForm.RootPane.AddNode(Screen, 0, 0, MainForm.Width, MainForm.Height) Screen.DrawRect(0, 0, Screen.Width, Screen.Height, fx.Colors.Black, True, 0)
kabron Member Licensed User Longtime User Oct 26, 2014 #8 Thank you, Erel, this works! But still a questions: Why it always works in Win8.1 x32 and under IDE in Win7 x64 without Screen.DrawRect()? Upvote 0
Thank you, Erel, this works! But still a questions: Why it always works in Win8.1 x32 and under IDE in Win7 x64 without Screen.DrawRect()?
Erel B4X founder Staff member Licensed User Longtime User Oct 26, 2014 #9 You will need to ask Oracle this question... Upvote 0