[codenameone-discussions] Re: phoenix theme differences

2017-03-04 Thread Shai Almog
Some differences are intentional we let the devices conventions "bleed into 
the UI" to provide a more familiar environment for the design.

The right way to get the theme to act the same is to override that specific 
attribute within your theme and force a value which will be applied in all 
platforms. 

In the case of tabs some of the look relates to OS specific theme constants 
https://www.codenameone.com/manual/advanced-theming.html just search for 
tab related constants to see which one impacts in which way.

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/ba10fdd2-15fb-4654-80ae-0092e8083cae%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[codenameone-discussions] Re: Possible bug in com.codename1.ui.EncodedImage.createFromImage(Image, boolean)

2017-03-04 Thread Shai Almog
Gotcha. It's odd that this would fail as that code has been there for a 
long while as far as I can tell.

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/4594d1ef-2679-42be-ace8-5e0f2698b1cd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[codenameone-discussions] Re: Any known exisiting issues with Nougat (Android 7) and CN1?

2017-03-04 Thread killerbeesoftware
Ok Shai,  I am going to try and build it this week and will report the 
results for you, I do believe I have someone that currently has the old 
failing build on a 7 machine, and would be willing to test a new one. 

thx.


On Friday, March 3, 2017 at 1:10:32 AM UTC-6, Shai Almog wrote:

> I got some reports that some old unmaintained apps also stopped working 
> with Android 7. 
> Obviously if you rebuild it then it should work fine but that might break 
> other things as Codename One changed a lot since 2014. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/3cc2f017-f13a-45d7-bf84-8a8d801608d7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[codenameone-discussions] phoenix theme differences

2017-03-04 Thread howudodat1
I have noticed some theme differences between the simulator (iOS base I 
assume) and what appears on my android device.  The differences so far are 
with MultiLine2 and Tabs.  I believe all I need to do is copy the elements 
from the iOS theme.  So I copied MultiLine1-4 and that worked.  I copied 
Tab, Tabs and TabContainer and it still doesn't match.  What else do I need 
to copy so that on Android the tabs are on the bottom and look like they 
would on iOS?  

Also on the simulator for android, the title bar is white with white 
lettering.  However on my actual Samsung, it shows ok.





-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/cea018d9-c7bf-4215-924c-987ccfa2d380%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[codenameone-discussions] Re: Possible bug in com.codename1.ui.EncodedImage.createFromImage(Image, boolean)

2017-03-04 Thread xhatti via CodenameOne Discussions
It doesnt matter if i pass true or false into the method. The base64 
picture is always just black.

The issue are these 2 lines in the createFromImage method:

Util.cleanup(bo);
EncodedImage enc = EncodedImage.create(bo.toByteArray());

swap then solved the issue

On Thursday, March 2, 2017 at 11:30:17 AM UTC+1, xha...@googlemail.com 
wrote:
>
> Hey ho!
>
> I may found a bug in the method mentioned in the title.
>
> My usecase:
>
> We want to send the image from a SignatureComponent base64 encoded to the 
> server.
>
> This is my sample code:
> SignatureComponent asSignature = (SignatureComponent) valueComponent;
> Image signatureImage = asSignature.getSignatureImage();
> EncodedImage encodedImage = URLImage.createFromImage(signatureImage, true);
> String asB64 = Base64.encode(encodedImage.getImageData());
>
>
> But i always get a black screen out of it and the base64 string is always 
> the same, no matter what image will be returned from line 2 in the code 
> above.
> I looked into the the "createFromImage" method and saw these 4 lines:
>
> ByteArrayOutputStream bo = new ByteArrayOutputStream();
> io.save(i, bo, format, 0.9f);
> Util.cleanup(bo);
> EncodedImage enc = EncodedImage.create(bo.toByteArray());
>
> I suppose the Util.cleanup method is like a Stream.close() equivalent, so 
> the last line "bo.toByteArray()" cant work propperly if the stream is 
> closed before. If you switch  the last 2 lines, it works as expected and i 
> get a valid image.
>

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to codenameone-discussions+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/ec00d841-e02a-44a7-867b-dac32ea2e7c0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.