Bill Farmer

Random thoughts on random subjects

Android Kotlin

by Bill Farmer. Categories: Hacking .

All my android apps have up until now been written in Java, avoiding the use of the support libraries or androidx. The Google developers docs and guides advocate the use of Kotlin rather than Java and the use of androidx almost to the exclusion of the standard android API. I have a very simple app, Oglaf, NS(Generally)FW, which is just a wrapper around the web site, with some navigation. So I decided to convert it to Kotlin, just to see how difficult it was and to see what effect, if any, it had on the app.

Read more →

Android Word Count

by Bill Farmer. Categories: Hacking .

I was asked to add a word and character count to my Editor app. So I looked it up and found a Gist that uses BreakIterator. This relies on an embedded function that determines what is considered a word. So I tested it and found that it gave different results to the linux utility wc. However, the app already makes great use of regular expressions, which include an expression for a word character \w.

Read more →

Pea and Ham (or Bacon) Soup

by Bill Farmer. Categories: Recipes .

This soup is somewhat complicated to make, but delicious. Marrowfat peas need to be soaked overnight. Ingredients Olive oil 1/3 cup dried marrowfat peas 1/2 teaspoon bicarbonate of soda 1/3 cup frozen or fresh peas 1/2 cup chopped ham or bacon pieces A medium sized onion, chopped finely Two or three cloves of garlic, chopped A stick of celery, chopped finely A medium sized carrot, grated 1/2 vegetable stock cube Milk Method Soak the marrowfat peas overnight in a bowl of water with the 1/2 teaspoon of bicarbonate of soda.

Read more →

Caldo Verde

by Bill Farmer. Categories: Recipes .

This is not the traditional method of making caldo verde. The cabbage should something like spring greens, collard greens or cavalo nero. Roll up the leaves and slice thinly. Delicious lunch for two. Ingredients Olive oil Two or three green cabbage or kale leaves, sliced thinly A medium onion, chopped Two or three cloves of garlic, chopped A medium sized potato, preferably floury type, chopped into cubes About half a dozen slices of chorizo, chopped into small pieces and another half dozen slices left whole Half of a vegetable stock cube Milk Method Cover the bottom of a small saucepan with olive oil and place on a low heat Add the chopped chorizo and allow to warm up until bubbling merrily Add the onion and garlic, the stock cube, the potato, and the cabbage/kale on top Cover and allow to steam until the potatoes mash easily with a fork Add milk to cover and mash most of the potato with the fork Allow to warm through until the milk starts to froth Meanwhile, warm up the chorizo slices in a small skillet over a gentle heat Season to taste and ladle into bowls, add the slices of chorizo and oil from the skillet on top Serve with toast or crusty bread

Read more →

Turkey Gammon Broccoli Bake

by Bill Farmer. Categories: Recipes .

This is a recipe for using up a Christmas turkey or chicken, gammon joint, veg etc. You will need a large saucepan for the veg and pasta, a small saucepan for the sauce and a casserole dish or similar to bake it in. Ingredients Cooked turkey/chicken, chopped Cooked gammon, chopped Broccoli, cut into florets Any other veg that needs using Penne pasta Cheddar or Red Leicester cheese Plain flour Onion, chopped Garlic, chopped Celery, chopped Black pepper Dried oregano Olive oil Milk Method Meat, Broccoli and Pasta First cook the broccoli and any other veg in a large saucepan in the minimum of water.

Read more →
Previous page Next page