]> git.sesse.net Git - vlc/blobdiff - modules/codec/libass.c
Qt: Simple Preferences: conditionally hide the whole groupbox, not
[vlc] / modules / codec / libass.c
index 97fd6eab97412ac7d3f51c01df905c01617ddb10..aa38f1b2f609072b6d003b46b7b4fd694dfebbd2 100644 (file)
@@ -1,24 +1,24 @@
 /*****************************************************************************
  * SSA/ASS subtitle decoder using libass.
  *****************************************************************************
- * Copyright (C) 2008-2009 the VideoLAN team
+ * Copyright (C) 2008-2009 VLC authors and VideoLAN
  * $Id$
  *
  * Authors: Laurent Aimar <fenrir@videolan.org>
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation; either version 2.1 of the License, or
  * (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
 /*****************************************************************************
@@ -42,7 +42,7 @@
 
 #include <ass/ass.h>
 
-#if defined(WIN32)
+#if defined(_WIN32)
 #   include <vlc_charset.h>
 #endif
 
@@ -210,11 +210,16 @@ static int Create( vlc_object_t *p_this )
     ass_set_font_scale( p_renderer, 1.0 );
     ass_set_line_spacing( p_renderer, 0.0 );
 
+#if defined( __ANDROID__ )
+    const char *psz_font = "/system/fonts/DroidSans-Bold.ttf";
+    const char *psz_family = "Droid Sans Bold";
+#else
     const char *psz_font = NULL; /* We don't ship a default font with VLC */
     const char *psz_family = "Arial"; /* Use Arial if we can't find anything more suitable */
+#endif
 
 #ifdef HAVE_FONTCONFIG
-#if defined(WIN32)
+#if defined(_WIN32)
     dialog_progress_bar_t *p_dialog =
         dialog_ProgressCreate( p_dec,
                                _("Building font cache"),
@@ -222,7 +227,7 @@ static int Create( vlc_object_t *p_this )
                                   "This should take less than a minute." ), NULL );
 #endif
     ass_set_fonts( p_renderer, psz_font, psz_family, true, NULL, 1 );  // setup default font/family
-#ifdef WIN32
+#ifdef _WIN32
     if( p_dialog )
     {
         dialog_ProgressSet( p_dialog, NULL, 1.0 );