Latest posts from Codename One.
Blog

Code Freeze for 3.5
Today we are going into code freeze for Codename One 3.5 which is due one week from now, because of the fast release cycle we don’t need more than a week of code freeze to stabilize our current release. The code freeze applies to the Codename One libraries and ports as those are the parts that are inherent to the release. What Didn’t Make the Release We have many new features and great capabilities that we were able to introduce for 3.5. We will go into those with our release announcement. ...

Logged Versions
When we get a crash report one of our first questions is “when did you build this?”. The answer is often too vague to trace the specific version, so we end up with a mixture of guessing. The main issue is that there are different version values. They conflict with one another. They can be confusing and they can be inaccurate. Starting with the latest update we now have a file in the root of Codename One called cn1-version-numbers and it includes two numbers that might not be accurate but will give us a general ballpark of the relevant version. The latter number is our internal SVN version number but the former can be interesting to you too. These numbers will appear as below when you make your first Log.p(String) call: ...

Questions of the Week XV
We are on the final stretch of 3.5 getting ready for the codefreeze that will go into effect in the middle of next week. With that in mind we have last minute features we are trying to get out of the door and unfortunately had to skip some big tasks. One of the big problems is the iOS server migration which we couldn’t fit into the schedule. The peer component changes made it to Android but aren’t set as the default, this makes the most sense in the current state. We’ll probably flip the switch to the new peer components after the release. ...

Featured App – Ana Paltel
Millions of Codename One apps are installed on devices every month. Most of them aren’t in the gallery and are never featured in this recurring segment. We are looking for something exceptional in apps that we feature here and Ana Paltel fits that bill. It has a polished UI and it’s shipped by a major operator. It uses some unique Codename One features to boot making it even more interesting. ...

How I Chose my Replacement for Parse.com
When I first read the announcement that Parse.com would shut down on January 28th 2017, I went from disbelief (it’s probably an early April fool’s joke) to rage (how could they do that?!) to sadness (oh no! it was a great service) and finally to utter confusion (where do I go from here and what do I do with my apps – parse4cn1, two MVPs for clients and an upcoming rewrite of Medex for which I was planning to use Parse.com as backend?). A few months down the line, a lot has happened such as the release of the open source Parse Server (yay!) and subsequently the Parse Dashboard. However, I still had to decide what do with my apps and I guess you have to as well. ...

Scrollbars & Tooltips
One of the big decisions we made a while back was to build the new GUI builder on top of Codename One itself, we extended that decision three months ago with the decision to build the Codename One settings in Codename One and then deciding to make it the default preferences UI for all IDE’s… Those were great decisions in retrospect, they helped us consolidate code across the different IDE’s. Furthermore using Codename One is far simpler than Swing/SWT or FX. At least for us… ...

Alphabet Scroll
We got a lot of requests from developers over the years to do an iOS style alphabet side scroll. Some developers implements such scrolling but no one made it generic or contributed it back. So a recent stack overflow question got me thinking about how easy it would be to actually implement something like that and I decided to try… I ended up building this in 10 minutes and the concept is remarkably simple. I have two containers, one contains the list of the people and the other one contains the letters used for these people. Notice that I chose to only use letters that used in the names, I could have just hardcoded the English alphabet but chose to avoid that as this would break for internationalization and include letters that might not be common in such cases such as ‘Z’. ...

Questions of the Week XIV
With the pending release and some important issues we decide to make a minor update to the plugin today to introduce some improvements. We want the GUI builder to stabilize so we can finally crown it as “the” GUI builder rather than as “the new” GUI builder. To do that we need you guys to use it and submit issues, we also need you to use the latest version… ...

Dynamic AutoComplete
With the fix for issue #1694 we can now have a moderately simple method of creating an AutoCompleteTextField that works with a webservice. This has been requested quite often and was quite frustrating to implement in the past it is now relatively simple with just a few lines of code. Check out the live demo using the JavaScript port on the right side here You can see the full working sample of this project in this github repository notice that you will need to fill in a google web API key for the webservice to work as explained here. ...

How to Build a Clicking (Tapping) Game Tutorial
Over the weekend LokeHansen posted a new series of youtube videos covering the process of creating a game in Codename One. I really enjoyed watching them as his teaching style is far more accessible than mine (I tend to be overly technical without noticing). I’m guessing the videos below might be a bit too simple for some of our typical readers but if you have friends or kids who like games and didn’t connect to coding this might be a great tool to get them started, I’ve embedded the first 3 videos in the series below. Check them out and subscribe to his channel for more. ...

Using the new GUI Builder
We had a couple of posts in the past about the new GUI builder but we didn’t have a “how to” guide yet. In this post we’ll try to go step by step over the process of using the GUI builder and understanding its inner workings. We’ll also try to clarify conclusively the role the new GUI builder plays in the toolchain and the migrations process from the old GUI builder. ...

New Android Peer Mode
As we mentioned recently we have a new idea on how peering can be improved and we just deployed a this into our build servers in the weekend update. This is highly experimental and might crash instantly which is why we hope you give it a test drive and see how it feels before we switch it on by default. To recap: Peers (or heavyweight components) are OS native widgets. E.g. when you use the BrowserComponent we effectively load the OS’s native webkit renderer and use that instead of showing HTML ourselves. This is good as it allows us to use OS native functionality, however it’s bad because peers have a lot of limitations which we covered in depth here. ...