add strlcpy() implementation for UTF8 strings

..and use it where applicable.

This fixed problem described by Alexandre - Unicode strings are cut in the middle of a Unicode character, see http://sourceforge.net/mailarchive/forum.php?thread_name=CAFjkzc01AC3DHvt7juvp2OC0iPFOaCbd5sHHzNFuPp_g6Ta9iw%40mail.gmail.com&forum_name=darktable-devel.