Layout Managers in Android: The Basics

Continuing my research into the Android world, I’m concentrating today on layout managers (or just layouts). The position of every single widget on the screen of the device is controlled by the layout manager. In some cases, the visibility (or lack thereof) is also determined by the layout manager. Fortunately, there are only a few…

The Things I Like (And Don’t Like) About Swift

Recently, I’ve given myself the task of learning the “native” mobile development platforms.  That means Java or Kotlin for Android and Swift or Objective-C for iOS development.  Kotlin is a ways behind Java for Android development and I already knew (somewhat) the Java language, so that one was relatively easy.  Swift is the new kid…

Simpler View Binding with Android

I recently wrote a couple of Android apps in the native Java language. One of the things I hated about this was the amount of boilerplate. First, I would create a UI element and give it an ID – something like: Then I would go to my activity and add a private variable for each…

Writing a Weather App for Android: Location

Over the past week or so, I’ve been writing a Weather App for Android using the cloud-based OpenWeatherMap API. The posts so far that cover this: Creating the Model for the OpenWeatherMap response. Creating a cloud Manager API for the client. Creating the UI for the app. Linking the UI to the data. Handling refreshing…

Catching Application Crashes with Android

I’ve recently been working on a Weather app. There have been occasions when the app has crashed. It hasn’t been a big problem in general, but problems are always big unless you know what the problem actually is. How do you trap all the exceptions? The answer is to use an Uncaught Exception Handler. Basically,…

Writing a Weather App for Android: Refresh

In the past few posts, I’ve been writing a weather app for Android in the native language using the OpenWeatherMap API – Java. You can check out the prior posts here: The Model that OpenWeatherMap uses. Getting the data from OpenWeatherMap. Writing the UI to display the weather. Linking the UI to the data. It’s…