How to set theme setting
As you can see in the code of theme_get_settings(), if data is not in cache, it's obtained from variables:

// Get the saved global settings from the database.
$cache[$theme] = array_merge($cache[$theme], variable_get('theme_settings', array()));

if ($theme) {
  // Get the saved theme-specific settings from the database.
  $cache[$theme] = array_merge($cache[$theme], variable_get('theme_' . $theme . '_settings', array()));


So usually when you need to change them from code, you will need to use good old variable_set(). And don't forget to clear the cache.