It’s been a long time…

It’s been a long time since I wrote on this blog. Time has passed more aggressively than I thought.

Many things has happened during the time, as most important one of them I found my lost inspiration in arts (Calligraphy, Visual arts and Film-making).

To my surprise, I’ve found that it’s definitely possible to shoot quality footage using relatively cheap DSLR cameras. When I found this, I went mad about doing that, but to buy a DSLR I needed time to sum up some money!

I’ll write more about my newly found adventure soon.

Farsi labels for Farsi Ordered Lists!

The javascript code below, can convert English numbered Farsi ordered lists to the correctly labeled ones!

<script type="text/javascript">
 //<![CDATA[
 $(document).ready(function() {
  $("ol").each(function() {
    var i = 1;
    $(this).css("list-style-type","none")
         .children("li").each(function() {
          var label = "";
          var order = i++;
          while(order >= 1)
          {
            label = String.fromCharCode(order % 10 + 0x6F0) + label;
            order /= 10;
          }
          if(label == "")
            label = String.fromCharCode(0 + 0x6F0);
          label += ".";
          var li = $(this);
          li.css("padding-right", "0px").css("margin-right", "10px");
          li.html("<span style="display:block; float:right; margin-left:10px;">" + label + "&nbsp</span>" + li.html());
         });
  });
 });
 //]]>
 </script>

Live in real – maybe dull – world or dream with movies

I’ve been long stuck in this very simple decision point. Believe me, for someone who lives with 7th art characters, it’s not a simple decision.
The obvious truth is that dreaming with movies will not give anything even long living and so is somehow useless. As such I’m trying to apt myself for acceptance of what I once heard from a cleric:

Not a single event in the whole universe happens without a precise purpose. God designs exactly what happens and designs them to help every single man to evolve. Seems pretty poetic, huh! When you look at world the way God want’s you to look, eventually it all becomes a sweet poem

LayoutRTL Problem of Delphi®'s PageControl

If you ever tried to apply WS_EX_LAYOUTRTL to Delphi®’s TPageControl you know what I mean. It happens that most of the time switching the pages cause disappearance of it’s content (i.e. it’s TTabsheet‘s content).

This is a small bug in Delphi®’s VCL. If you have purchased it with source code and can update the source for TWinControl and TControl. I’ve got a good solution for this problem. Just change the UpdateBounds procedure in both of them.

In both of above mentioned procedures, there are four identical lines like:

procedure TControl.UpdateBoundsRect(const R: TRect);
{procedure TWinControl.UpdateBounds(const R: TRect);}
begin
...
  FLeft := R.Left;
  FTop := R.Top;
  FWidth := R.Right - R.Left;
  FHeight := R.Bottom - R.Top;
...
end;

Just update them like what follows:

procedure TControl.UpdateBoundsRect(const R: TRect);
{procedure TWinControl.UpdateBounds(const R: TRect);}
begin
...
  FLeft := R.Left;
  FWidth := R.Right - R.Left;
  if FWidth < 0 then
  begin
     FLeft := FLeft + FWidth;
     FWidth := -FWidth;
  end;
  FTop := R.Top;
  FHeight := R.Bottom - R.Top;
...
end;

Order and discipline

Tonight once again I noticed the value of order and discipline. I think one would get to what he wants just by respecting these two powerful principles when he has considered certain values and goals.

I have had a long list of things I would like to accomplish yet due to lack of these two factors I have achieved a slight amount from the whole.

From now on I hope a better management of time using these gems and propose you to use them too!

Existence of God

Does the God exist?  In my opinion this is the most basic question one can ask himself and search his innermost beliefs for it.

Recently after a not so short discussion in my work-place with my other colleagues, I did that again. Thought as deep as I could and searched the internet to find any useful resources in this regard.

The best resource – as in many cases – was the Wikipedia. After a very fast and unsafe view of various theories in this regard the conclusion was “The reasons confirming God’s existence are far more precise and acceptable than the contrary.”

The strongest reasoning for atheism seems to say that “we can’t prove that God exists.” but the existence of God is not that way, in most of them a meaning, a clue is given.

Finally this is why I believe in God: In my daily life I don’t accept that events are not meaningful and no events in my point of view occurs suddenly and without reason. The whole existence seems to have spirit and is full of events so there must be a cause, a reason and that’s God. I think for anyone who doesn’t look at existence in an odd manner, anyone who don’t think that things happen out of nowhere should agree with me!

I suggest you to have a look in the corresponding Wikipedia page.

Merci pour cette belle aventure

I’ve recently watched the “Up” movie. An outstanding masterpiece from Pixar animation studios. I don’t call it another masterpiece because it differs an order of magnitude in story and genre.

I couldn’t even imagine that a story with essence of French romanticism could show the most in depth loyalty and freedom of soul. A picture of true love between a man and a woman who bet their lives loving each other and gain the most magnificent reward one can imagine.

An energetic yet loving lady lives with a loving husband. During her life, she never lives bad because of the environment or what happens. She enjoys a real life and gives another to her husband. She does not postpone a joyful life because her childhood dreams haven’t yet came to life. She does not postpone a joyful life because of her problems. And finally she does not let her husband grieve because he couldn’t do what he wanted for her…

Once I watched the movie, I cried and I cried and I thanked Allah for giving me the chance to remember that I’m living with such an angel and I’m ignoring this gift.

This is for you my love. This is because of you that my life has gained meaning.