Sitemap
A list of all the posts and pages found on this site. For you robots out there is an XML version available for digesting as well.
Pages
Page not found. Your pixels are in another canvas.
A first look at the Bash shell and the most important things you need to know about it.
The Basics
Sorry, but this content isn’t ready yet.
Taking a first look at how we’ll display the various counters used for the defending units.
Now we are ready to start building an application that actually does something. We’re going to build a CRUD (Create, Retrieve, Update and Delete) application for a customer database.
Blowing things Up: CyberTank Combat - Part 1
CyberTank Movement - Part 1
CyberTank Movement - Part 2
What you need to know about directories and listing files.
Examining how “Drag and Drop” works and using it to deploy units on the map.
Our first look at overall game structure and how the other parts are contained within it.
Global Data
HexMap
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
Intermission - Progress So Far”
Introducing a course for programmers starting out to learn JavaFX
A guide to show you just information to get you going with Linux, or to manage your new Raspberry Pi.
An Introduction
Oops! Forgot about Light Tanks, and they have a different unit cost. How are we going to fix this?
MOOSE: Mechanical Ogre Opponent Simulation
The very first step. What else? “Hello World” in JavaFX.
The last problem with our application is that it can save duplicate customer records, corrupting our database. This means adding some rules to our database and telling our GUI when those rules have been broken. We’ll see how to handle exceptions from the back-end in our application.
At this point we have a pretty clean “Create” application. It’s error resistant, doesn’t corrupt our database and ready to add some more functionality. Let’s look at what we’ve done so far.
It’s finally time to add a third field to our screen! In this article we’re going to add just a single new field, for email, to our screen. We’re going to see how the process goes from the View all the way down to the Broker. Most importantly, we going to see how we need to be vigilant in ensu...
In this article we’re going to look at how Feature Envy has crept into our View code. We’re going to look at why this happens, and how to deal with it. Finally, we’re going to see how clearing out Feature Envy makes our code much cleaner and easier to understand.
Some basics about building layouts and making your screens look the way you want.
GUI applications need a way for the user to interact with them. In this lesson we’ll show how to allow user input with TextField, and to launch an action with a Button.
JavaFX includes Cascading Style Sheets for styling the elements of your GUI. This is a quick guide about how to use them.
Building an application that “does something” means adopting a framework that works well with JavaFX. Here we build the skeleton of the Model-View-Controller-Interactor framework that we’re going to use for our CRUD application.
The first feature for our CRUD application has to be “Create”. In this lesson we’ll get started by designing the GUI and connecting it to the Controller.
In this lesson we finish up a “bare-bones” Create function by building the back-end and connecting it to the business logic in the Interactor. Part of this involves creating a simulated database.
Now we’ve completed the core programming for our “Create” function, where do go next. We’ll look at the idea of a “Product Backlog”, and talk about how we should prioritize our next steps.
Our simulated database doesn’t really do a good job standing in for a real database because it works too fast. We’ll slow it down and see what horrible things this does to our application. Then we’ll see how to deal with this.
We’ve also got a big problem with our application because there’s no data validation in our screen. This means that users can save invalid customer data. We’ll look at how to cope with this properly.
What you need to know about process, resources and management of them.
Now we are ready to look at how to start a game by letting the user position their forces.
Examining how the side-bar for selection of defending forces works.
After integrating Light Tanks, back to how the sidebar works.
How to get started.
Tiles are the autonomous units of display in the Hex Map. Let’s see how they work.
Looking at how clicks on the max hexes during setup can be used to remove units from the map.
Things you need to know about users, groups and permissions.
Custom controls and components for JavaFX layouts
Introducing
A Kotlin-based library of factory methods, builders, Properties and custom controls to make JavaFX development easier.
Introducing
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
PragmaticCoding is all about … pragmatic coding! Writing code that gets the job done and is easy to read, understand, maintain and enhance.
Posts
A comprehensive guide to styling TableView with tutorials and a reference of all of the styling selectors available.
If you are going to do any custom styling in JavaFX, you need to understand at least the basics about the Modena stylesheet and how it works with the standard JavaFX Nodes.
ObservableLists are used in a number of JavaFX elements, such as TableView, ListView and ComboBox. But what are they, and what can you do with them?
JavaFX 23 delivers a new feature - CSS Transitions! Let’s take a look at how this works and what you can do with it.
If you are a beginner with JavaFX and are wondering, “What are all these Property things anyway?”, then this is the article for you.
Taking a look at the structure of the JavaFX ComboBox, and how to do cool things with it.
A look at the Observable classes that wrap ObservableList
Confused by the plethora of Property, Binding and Observable classes? This guide will tell you what you really need to know about the typed Observable classes.
Confused by the plethora of Property, Binding and Observable classes? This guide will tell you what you really need to know about the generic Observable classes.
Looking for a framework that works with JavaFX as a Reactive platform? Here’s how to get started with Model-View-Controller-Interactor (MVCI) without a lot of theory.
A look at how to extend the idea of Bindings to include internal state to encapsulate the mechanics of more complicated relationships between ObservableValues in your GUI and your Model.
A deeper look at the Task class and how to monitor progress while a Task in running on a background thread.
What if you need to control the styling of a Node over a range of values? How can you do that, and is there any way create a framework that you can use over and over again?
Understanding the Model-View-Controller-Interactor framework is one thing, but putting it all together to create a large and complicated application means that you’ll need to know how to integrate it with external services.
Another look at some beginner code, and how it could be improved.
A quick guide get started with Gradle in the Intellij IDEA IDE.
There a little known, but very useful function call in most Properties. This can be overridden to turn a Property into a class that transforms a value change into an action.
Taking a look at a JavaFX application that suffers from some very common beginner mistakes, converting it to Kotlin and sorting out the issues.
Here’s a sample application that uses a ListView to display and edit bytes in a data file, showing the values in hex, octal, binary, decimal and as characters.
Taking a look at how EventHandlers, Listeners, Subscriptions and Bindings are different, and how they should be used in a JavaFX application.
Another example of creating a custom class. This time to build a container with a border and a Label that sits on the border.
Looking at ListView as a scrolling region of customized layouts, not just a list of String.
Is there such a thing as a “Right” or “Wrong” when looking at different approaches to solving a programming problem? Can one approach be objectively better than another? Spoiler alert: yes, it can.
How to build a radial menu in JavaFX.
In JavaFX 19 and 21, new methods have been added to the Observables library that should change the way you write Bindings and Listeners
We’re going to look at coupling: What it is, why it’s bad, and the ways that it can creep into your code.
One of the toughest problems beginners encounter is resources that won’t load. Here’s how to figure out how to organize your resources and how find them with your code.
An introduction to ListView and understanding how to use it to display something more than just lists of Strings.
In this article, we taka a look at how TableView handles data, the mechanism that move data in and out of TableCells, and how to work with it.
What is a TableView and how do you use it? Here’s enough information to get you started with TableView the right way.
An introduction to JavaFX Skins and Skinnable and how to create your own skin.
Once you’ve decided extend Region to create a custom control, there are some basic things you should do to make your new control look professional and unified. Here’s how to do that.
Creating a custom control really isn’t that hard to do. But when should you use one, and when should you just use a builder to create a layout?
Lot’s of programmers think that FXML instantly gives them as step up on Model-View-Controller, with the FXML File yielding the View and the FXML Controller acting as the Controller. We’ll look at why this isn’t correct, and how you should implement FXML in the context of MVC.
How to create custom control in JavaFX. Here we look at how to build a three position toggle switch.
The Bindings class is a utility library that provides a huge number of helper methods that can create and manipulate Bindings. Understanding how to use this library can make your code much simpler and easier to read.
Interested in programming JavaFX in Kotlin? Here’s what you need to know to write JavaFX code that is so much better than anything you can write in Java.
Dialogs are the basic tools for interacting with the user in a controlled way as part of a procedural flow. They are best thought of as a way to collect and return information from the user.
Here’s some basic information that everyone needs to understand before they can start building screens with JavaFX…The layout classes and how they are used.
Need to understand a Kotlin program, but you only know Java? This article should give you everything you need to know to get started.
An introduction to a framework that works better with JavaFX than MVC or MVVM.
How to set up a more complex project with multiple screens with varying levels of connectedness.
Taking a look at the three most common design patterns for building systems with user interfaces. How are they different? Which one is best? Is there anything better?
Introducing a “course” for programmers just starting out with JavaFX. Everything you need to know to get from absolute zero knowledge to building real applications that do real work.
Taking a look at the three most common design patterns for building systems with user interfaces. How are they different? Which one is best? Is there anything better?
This article contains all of the information you need to get started with cascading stylesheets in JavaFX.
How to handle image animation with Sprites and scrolling backgrounds
“Hey you jobs! Get off my FXAT!” Learn how to deal with the JavaFX Application Thread - How to get your background jobs onto their own threads the right way, and how process the results back on the FXAT.
Custom binding classes aren’t used that often, but understanding them is the key to understanding how to use the Bindings library builder methods.
The best way to structure an application is to separate the presentation of your data from the logic of your application. That can be hard to do. But not if you take an approach where you configure your screen elements, put them in the layout and then discard any reference to them.
Let’s look at Image and ImageView. How they relate to each other, and how to use them.
A look at how Optional works, and how it isn’t really about Null values - at least not if you were doing it right before Optional.
Another game based project. This time to see how to build an application with the main UI made of a “hex map”, commonly used in war gaming and RPG’s.
Maybe you’ve figured out how to build a working GUI that looks good. Now, how do you connect it to the rest of the world and make it do something?
ChangeListener or InvalidationListener, which is right kind of listener to use?
The original Wordle is JavaScript in a browser, here’s an implementation of it in Reactive JavaFX written in Kotlin.
Pseudo Classes are the best way to handle on/off state changes in a Node in JavaFX. But it’s very badly explained in the JavaDocs and hard to understand. This article should clear that up.
Everything you need to know about Events
Let’s look at Buttons.How to set them up and style them, how to use them, and things to look out for.
Stand-ups, Retrospectives, Sprints, Scrum Masters. Is it just bureaucratic nonsense that gets in the way of good programmers doing their thing? It shouldn’t be.
Kotlin has been described as, “The language that Java would have been if it had been designed 25 years later”. It’s starting to pick up popularity, and has had a boost from being endorsed by Google for Android development.But you’re not an Android developer, so should you learn, and use, Kotlin?
An approach to implementing the JavaFX Property “bean” structure for observable objects in an idiomatic Kotlin fashion.
I’ve always advised that Scene Builder and FXML are a waste of time, and that you should just write your screens in Java code. It’s easier to build, it’s easier to customize, easier to maintain, and much, much easier to do really sophisticated things. But how do you start?
Comments in code are supposed to help other programmers understand your code so that they can build on it, improve it and, sometimes, fix it. Are the comments that you’re leaving in your code helping anyone to do that?
How much code does it take to build a complete Hangman game in JavaFX?It turns out … Not much!
Is the Single-Threaded JavaFX GUI a Limitation?
PropertyValueFactory is an obsolete convenience method designed to eliminate boilerplate. We don’t don’t need it any more now that we have Lambda expressions.
There’s a lot of ways that software development projects can fail, or partially fail. Some of these happen when the users don’t understand as much as you think they do about what you’re building, how it will look and how it will work.
Model-View-Controller is generally accepted as a good way to structure an application with a user interface. Since JavaFX implements Reactive programming there’s a natural way to incorporate MVC into a JavaFX application. However, it doesn’t seem to be widely documented and there’s little evide...
In Part 2, we’ll build a filter and converter which will handle decimal data input with a fixed number of decimal places.
JavaFX contains powerful tools to turn simple TextFields into specialized entry fields for any kind of data you can think of.
MineSweeper! Everyone’s favourite time-waster Windows game. Implemented in JavaFX showing how the reactive nature of JavaFX can be used with MVC to create a game.
Stop treating your JavaFX controls as data and passing them global EventHandlers.