Wednesday, November 30, 2016

In 2009 I started playing with an RTF control and I created one organizer for my own need to store articles and any other useful info I can find in the web for later offline reading and reference. I decided to do that because most of the time we don't have good internet here.

Well I was reworking the previous days on that old DevOrg app which consisted of a treeview and an RTF activeX controls as I decided to finally give it a filtering capability, insertion of image with rescaling and quality reduction, reworking the icon panel to look like a ribbon, etc.; and along the way, I thought of allowing it to highlight the words I typed to filter the threads and nodes of treeview. So I can see outright where those are, like this:

The trick is to work behind the scene on its RTF codes. Here is the method I created for that:

If you notice, I have used three (3) possible cases, i.e., UPPER(), LOWER() and PROPER(). The problem is I can't force the RTF codes to any of these cases alone to ensure I can highlight everything as that will also affect the output. So say I filter threads for entries with the word "javascript", then it can find and highlight words with javascript, JAVASCRIPT and Javascript. But not JavaScript.

While I can instruct it with another function/method to look for any other transmutation of the word like JavaScript, JAvascript, jaVaScript, etc., I think that is an overkill for this simple need of mine.

So anyway, I am just showing here the trick on how to achieve that in case you use and RTF tool on your end and wanted to have the same on your end. Cheers!

Monday, November 14, 2016

Another button class for my need which may come handy to my subscribers as well.

So why make another one? What is the main difference with this one vs say ButtonX?

On my BizCore ERP app, I use TreeView for my menu as I can easily control there what can be shown per user by hiding/removing nodes they should not be of concern. See ERP app below:

However, for comparably smaller app like my Gift Voucher one, my GUI approach is different where I use background images plus images representing as button icons. Why this design? First, I want to give my users the capability to change wallpaper via a simple double-click. That adds to user satisfaction because they won't be tied up with an appearance that they may not like as each user has his/her own taste. Another is to make the app look bigger, LOL! Here is that app showing different look impact by simply changing wallpapers.

And for that design, I need to have a button that will appear transparent and so this new control class. ButtonX can be made transparent too via making nTheme parameter 0 (zero) and nLineSpecialEffect = 3. However, when you do that, you won't see any hover effect (glowing blue) I did on MouseEnter here because that is tied up on the theme image which we ignored for transparency sake. And so it is a bit harder to see where you are except on relying on the mouse pointer.

Unlike my other button classes, I made this one simpler via allowing the use of PEM instead of us typing This._setting(....) inside the class init. So you can go to PEM and change its Picture, Caption, Enabled and ToolTipText. Speaking of Enabled, when the class is toggled to disable, then these two (2) properties will have an effect on its appearance:

1. _noHighlight (Default is .T.) - When the class gets disabled, you won't see the hover effect of that glowing blue background. Turn it to .F. to show that hover effect even if the class is disabled.

2. _ShowLock (Default is .T.) - When the class gets disabled, a lock icon will appear on its top as additional visual guide. If you don't want this, turn this property into .F.

Thursday, November 10, 2016

Last time I have shown how to employ ticking/unticking of checkboxes on Grid with AllowCellSelection = .F. via utilizing MouseDown event of Grid. So what makes this different than the first trick? The first trick relies on Relative Column of Grid. And this poses a problem when the columns are reordered via dragging into new position as Relative Column will then change.

So it is not that foolproof and only will work when you don't rearrange the column orders. This one though fixes that as this is no longer based on the relative column's position but will be basing on the ControlSource of that column.

Monday, October 31, 2016

Sorry, this is not about software developing. I just wanted to create this entry here for my latest hobby which is pencil drawings.

When I was young (in elementary and highschool), I used to draw using a ballpen. Then I stopped as my focus went elsewhere. That was 29 years ago.

Last month, for whatever reason I decided to see if my hands are still there. So I ordered a pastel color pencil in ebay and started making some sketches where immediately after completion, I posted it on my wall. And while I deem my output as elementary, my friends say they love those.

Since I realize I don't have the patience required of a real artist as I want to draw and finish whatever I am working within just a few hours, I put aside my pastel (I realize that requires patience) and I decided to work on pure pencils as making shadows there are easier. While I do not have the proper grades (I lack 7b, 8b and 9b for darker ones), my friends also loved those as well so they started requesting I draw them. And I did.

One time I decided to draw my departed brother. Heck if I can take time to draw my friends, I will spend time to draw my loved ones too. I have to draw him twice before I believe I got an acceptable output. Today I decided to see how it will look like when in color.... so Photoshop color layering. Below is the source pencil and photoshop output

Wednesday, May 18, 2016

While I do not want to involve politics on my blog, I will make an exception for these thoughts; hoping it can reach more of my countrymen.

I am not a loyalist, never was and never will be, even with du30 no matter how good I see he is. Because most of the times being a loyalist clouds a person's perspectives, and that I won't let happen to me. Studying du30's character, he does not want it too. He wants people to correct him if he is making a mistake too.

I don't want to be a loyalist for my need to see the good and acknowledge the faults. The same way I like my friends and family members to see and treat me too. Then to balance those visible actions out to build a more accurate composition and assumption of a person's character.

I can never be a loyalist because I don't and will never blindly follow anyone without analyzing the implications of a move.

The problem with us, Filipinos, is most of us has this personality disorder (yeah it is a disease) of following blindly a leader, from the baranggay level up to the highest position. "Sabi ni kapitan, sabi ni boss tsip, gawin daw natin yan!" "Hindi ba bawal yan?" "Walang bawal bawal, sagot ni kapitan at konsehal yan". How I wish we should learn to question and oppose our leader if what he/she is doing is wrong. Hey, nobody is born perfect so learn to acknowledge their mistakes, and oppose those.

Another problem that I see is we filipinos are in awe of those in power thinking of them as "royal bloods" and that leads to us ourselves enabling them to build political dynasties. Once a person was voted to hold a higher position, we gave them more powers by also voting for their family members to hold other positions in the government too when they decided to run because the thinking is they are "entitled" or mostly suited than others to do that; again because of that royal blood mentality.

We also view the politics like a beauty contest where popularity is a major factor. And this resulted to some movie actors/actresses holding key government positions. I am not saying they are not capable to hold those positions as there are some who has the interest of their community at heart like Gov. Vilma Santos; to name one. I am just saying that we based hugely our casting of votes on popularity, not even minding to do a research on a candidate.

With this attitudes of ours, political dynasties of families are born on parts of the country (Josons, Marcoses, Umalis, Ampatuans, Binays, Aquinos; to name a few). Later we come to regret this but it is too late. Later we shout at the abuse we get. And whose fault is it anyway?

Most of you forgets that they (government officials) are elected to "serve" the country and its people and not to be "revered" as the almighties. And that we should be more in power and has the right to question their wrong actions.

I am never a loyalist as I can easily see beyond facades, beyond sweet talks and empty promises during election time. Because I don't easily believe in words but look at existing and previous works.

Having said, as this write up has been spawned by my post of Marcos' accomplishments, I came into conclusion long time ago that Filipinos have been deceived by cries of oppression and how bad martial law is. Because when I put the next governments in comparison, I saw only more rampant corruptions and sweet talks with the later regimes. I saw that those self-claimed victims of martial law are the ones who have benefited the most on the next regimens, financially and politically; massively.

And since they enjoy fully those benefits, they continue to use until now the bad side of marcos' regime as propagandas to hold us in our necks forcing us to look only on what they want us to see. Not surprisingly because if and when you look around and compare their achievements, collectively all of them lack in comparison with what the late Marcos has done. Way way down below.

What makes me angrier is they are aided by paid and bias medias, just to continuously misdirect the attentions of the citizens so we will only focus on the "bad sides" of marcos. These sleight of hands should stop. I urge everyone, when they start shouting about the past, look instead in the current and see what they've done. Doing so will lift the fog that is hiding their own corruptions, malpractices, and non-accomplishments & very poor jobs. The things they don't want us to see and the reason for misdirection and mind conditioning.

It is not bad to be a loyalist people, but don't be a blind loyalist following your chosen leaders even though when they are wrong.

And finally, I AM A LOYALIST! My loyalty though is towards my country for I want what is good for it and abhor the bad things they are doing to it. So I will support those that have proven by actions to have the country's interest by heart. No matter who he/she is, no matter what parties they are in.