Showing posts with label up. Show all posts
Showing posts with label up. Show all posts
Wednesday, April 12, 2017
Monday, April 10, 2017
New Comic Foundry Magazine Up
New Comic Foundry Magazine Up
Its the beginning of the month, which means a new issue of the Comic Foundry online magazine. Check it out here.
This month even has the added bonus of a piece by yours truly, "The 25 Most Important Events in Comics in the Past 25 Years." Check it out here.
Available link for download
Friday, April 7, 2017
NET lacks action cant keep up with Swing
NET lacks action cant keep up with Swing
Microsoft has really not understood the concept behind the GUI design pattern Model View Control (MVC). As I understand .NET can not connect GUI controls to functionality (logic) objects (that would be linking View to Control). Ive asked this question on common .NET sites, usenet groups and it seems that they missed out on this part totally. To me, it shows that the .NET Forms project was really rushed and misses major parts that Swing has had for 8 years.
What I am talking about, is that Java Swing has Action classes that can be linked to GUI controls, which means that the GUI control uses the Action object when it has been activated (clicked for buttons, menu items, combo boxes, lists and even tree controls) . This Action class contains only the logic (Control) and nothing else; when activated from a GUI control it will perform its functionality. The drawback with this approach that every major action needs their own class, which generate many more classes. But the benefit is that you can have several buttons/menu items, that uses ONE class to do a certain functionality. It helps during maintenance, where I am right now. This is nice, when a certain Action is disabled (for instance Save is disabled when the user doesnt have an active document); because it will notify ALL controls that is connected to the Action object. So the developer does not have to care which dialogs/forms/menu that are visible and must be disabled, etc. It is just one simple method call, and that is the beauty of it.
Another nice thing with it, is that the Action class contains most of the important properties for a control:
* A name (for buttons) (can be localised)
* A short description (read tool tip) (can be localised)
* A key accelerator, for short cut keys
* An icon (next to the text in buttons and menu items)
* An mnemonic key
So when I need to create a button and menu item, all I do is:
anAction = new FileSaveAction();
JButton button = new JButton(anAction);
mainFramePanel.add(button);
JMenuItem menu = new JMenuItem(anAction);
mainFrame.getJMenuBar().getMenu(0).add(anAction);
anAction.setEnabled(false);
//.. user opens a new document
anAction.setEnabled(true);
The above code will create a button in the main frame panel, and a menu item. They will have the same text, the same icon, the same tool tip AND both are disabled at the same time. When the user opens a new document it is just one method call to enable both controls. Magic, isnt it? Or is it just properly designed?
At my current project, which is a huge .NET project, they have many menu items and buttons that each of them needs to be enabled/disabled when some functionality is disabled. That generates alot of excess code that isnt needed and is hell to maintain. Since the application is localised in 5 different languages, the developer needs to code enable/disable functionality for least 2 GUI controls. And this means that each control needs 5 different localisations which needs to be set. Talk about unnecessary and unwanted work.
Available link for download
Monday, February 27, 2017
Natural Ways to Speed Up Healing of Fractures
Natural Ways to Speed Up Healing of Fractures
Depending on your fracture, doctors will probably put a bandage or a fiberglass or plaster cast on your fracture. Then they will give you pain killers and tell you to let the bone heal naturally for two to three months. However, at home, you can do following:
- Eat fresh pineapple everyday. Pineapple is rich in Bromelain, an enzyme that helps reduce inflammation. If you cant find fresh pineapples, you can take the supplement Bromelain.
- Take calcium, magnesium, potassium, vitamin K and boron. They are essential in repairing bone damage.
- Take vitamin D as it aids in clacium absorption.
- Take vitamin C as it helps in the formation of collagen.
- Take zinc to help repair tissue damage.
- Eat foods that are rich in calcium and other nutrients needed for calciums assimilation such as sea vegetables, green leafy vegetables (kale, romaine lettuce and other collard greens), soybeans (tofu, miso), nuts, molasses, salmon, oysters, sardines, broccoli and unsweetened yogurt.
- Essential fatty acids are important also and can be found in walnuts, almonds, flaxseeds, and fish.
- Avoid red meat and products containing caffeine as they increase calcium excretion. Sugar and high intake of salt contribute also to bone loss.
- Avoid eating food with preservatives. They conatin phosphorus which can lead to bone loss.
- Stop smoking. Smoking slows the blood flow to the bones, thus slows down the healing process.
- Stop drinking. Alcohol slows the formation of the new bone cells.
Available link for download
Wednesday, February 22, 2017
Nothing like a little whoop as to wake up the legs
Nothing like a little whoop as to wake up the legs
Ive not been too motivated to ride much. Its the endurance phase and when I have been able to ride I go deathly slow in order to make the time pass longer so that when I get back home my ride time is higher.
My friend and I joined a group ride yesterday and it was a shocker. Right from the start these guys were flying. I was going hard enough to wheeze and wish for an inhaler. Within the first 1/2hr I was thinking of breaking off just to go at an easier pace. I ask myself if it is a good thing to be going too hard too early.
But the fact is this isnt somehting I do on a regular basis. A good smack down on my legs even this early helps wake me up, get the legs going and helps to motivate me. But still it was still way faster than Id be going if I were by myself.
Weve gone from high 20s to mid 60s in a week. Better enjoy it while I can.
Available link for download
Wednesday, January 25, 2017
Subscribe to:
Posts (Atom)