Today's Question:  What does your personal desk look like?        GIVE A SHOUT

SEARCH KEYWORD -- Tricks



  Macro vs. Micro Optimisation

So there's recently been a bit of hype about another Colebourne article: http://blog.joda.org/2011/11/real-life-scala-feedback-from-yammer.html I'd like to respond to a few points he makes. First - You should evaluate Scala and pay attention to its benefits and flaws before adopting it.  Yes, there are flaws to Scala.   Working at typesafe makes you more aware of some of them.  We're actively working to reduce/minimize/get rid of these.   In my opinion, the negat...

   Optimization,Performance,Micro,Macro,Software     2011-11-30 12:04:25

  Ways to make elements in HTML center aligned horizontally

In our daily HTML design,  it is an easy job to horizontally center align an element with known width. <div class="element">I am<a href="http://www.aiubug.com" target="_blank" rel="external" title=""> bug </a>!</div>  .element{width:960px;margin:0 auto;}  The above codes set the width of the div block and horizontally center align it. It's very easy to implement. However, if we have some elements we don;t know their width and we still want to...

   HTML,CSS,Center align,Unknown width     2012-07-11 12:55:00

  How to Create Custom Textures using Filters & Layers?

Textures are an important and integral part of the design world. You would find textures in every nook and corner of your life, in every space across your home. For a long time people have looked at Photoshop as a tool to manipulate photos and make them look the way you want it to appear. But, that’s not all to Photoshop. You can create interesting textures, and create amazing design works using Photoshop too. All you need is a design hand, and some basic understanding of how to use it. He...

   Photoshop     2014-08-01 05:46:07

  CSS Rounded Corners In All Browsers (With No Images)

In the past two years, increased browser support has transformed CSS3 from a fringe activity for Safari geeks to a viable option for enterprise level websites. While cross-browser support is often too weak for CSS3 to hold up a site’s main design, front-end developers commonly look to CSS3 solutions for progressive enhancement in their sites. For instance, a developer might add a drop-shadow in Firefox, Safari and Chrome using -moz-box-shadow and -webkit-box-shadow, and the...

   CSS,Rounded corner,No image,IE,Chrome,Fi     2011-06-30 22:50:34

  Google Chrome Alternatives: Best Browsers For Android

Most Android phones come with Chrome pre-installed as the default browser. There’s nothing wrong with that. Chrome is a great browser with excellent features. And it feels natural alongside all the other Google products that also come pre-installed on Android. But the type of browser someone uses is super important. In the end, the browser may be one of the most-used apps on any phone.  Browsers need to fit the needs and lifestyle of the person who is using it. To name a few examples,...

   FIREFOX,MICROSFT EDGE,CHROME     2020-06-18 07:12:35

  Optimization Tricks used by the Lockless Memory Allocator

With the releasing of the Lockless Memory Allocator under the GPL version 3.0 license, we can now discuss more of the optimization tricks used inside it. Many of these are things you wouldn't want to use in normal code. However, when speed is the ultimate goal, sometimes we need to break a few rules and use code that is a little sneaky.The SlabA slab is a well-known technique for allocating fixed size objects. For a given object size, a chunk of memory is divided up into smaller regions of that ...

   Optimization,Memory allocation     2011-11-16 08:02:16

  Comparing Floating Point Numbers, 2012 Edition

We’ve finally reached the point in this series that I’ve been waiting for. In this post I am going to share the most crucial piece of floating-point math knowledge that I have. Here it is:[Floating-point] math is hard.You just won’t believe how vastly, hugely, mind-bogglingly hard it is. I mean, you may think it’s difficult to calculate when trains from Chicago and Los Angeles will collide, but that’s just peanuts to floating-point math.Seriously. Each ti...

   Floating point number,Comparison,True value     2012-02-23 07:11:03

  C Macro Tips and Tricks

Preprocessor vs Compiler To properly understand C macros, you must understand how a C program is compiled. In particular, you must understand the different things that happen in the preprocessor and in the compiler. The preprocessor runs first, as the name implies. It performs some simple textual manipulations, such as: Stripping comments. Resolving #include directives and replacing them with the contents of the included file. Evaluating #if and #ifdef directives. Evaluating #defin...

   C,Macro,Preprocessor,Trick     2012-05-01 06:49:05

  Learn How to Write iOS Apps

My friend contacted me on twitter and asked for advice on different sources on how to learn iOS apps. Since this paragraph will already exceed 140 characters, I'm posting here, instead. (Obviously, reading this blog regularly is a great way to pick up some iOS development tricks) To get started, some people buy a book or find some good online tutorials. I tried both approaches, and the online tutorials were definitely better. I found Stanford's class on iPhone Development, available for free...

   IOS App,Tutorial,Advice,Resource     2011-12-25 00:58:25

  Buffcacher

What should a ‘cache’ be? It means a lot of things, but to my mind the default programming type should be: “keep around expensive-to-generate bits of read-only data in case we need them again, or until the computer really needs that RAM for something else” I was writing a custom video editing program in Python (interesting choice of language for that problem) and I wanted to cache decoded frames; but I just wasn’t happy with the memory management of explici...

   Buffer,Cache,Web browser,Memory,RAM     2012-02-24 05:10:10