+void BC_Resources::new_vframes(int n, VFrame *vframes[], ...)
+{
+ va_list ap;
+ va_start(ap, vframes);
+ for( int i=0; i<n; ++i )
+ vframes[i] = va_arg(ap, VFrame *);
+ va_end(ap);
+}
+
+VFrame *BC_Resources::default_type_to_icon[6] = { 0, };
+VFrame *BC_Resources::default_bar = 0;
+VFrame *BC_Resources::default_cancel_images[3] = { 0, };
+VFrame *BC_Resources::default_ok_images[3] = { 0, };
+VFrame *BC_Resources::default_usethis_images[3] = { 0, };
+#if 0
+VFrame *BC_Resources::default_checkbox_images[5] = { 0, };
+VFrame *BC_Resources::default_radial_images[5] = { 0, };
+VFrame *BC_Resources::default_label_images[5] = { 0, };
+#endif
+VFrame *BC_Resources::default_menuitem_data[3] = { 0, };
+VFrame *BC_Resources::default_menubar_data[3] = { 0, };
+VFrame *BC_Resources::default_menu_popup_bg = 0;
+VFrame *BC_Resources::default_menu_bar_bg = 0;
+VFrame *BC_Resources::default_check_image = 0;
+VFrame *BC_Resources::default_filebox_text_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_icons_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_updir_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_newfolder_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_rename_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_delete_images[3] = { 0, };
+VFrame *BC_Resources::default_filebox_reload_images[3] = { 0, };
+VFrame *BC_Resources::default_listbox_button[4] = { 0, };
+VFrame *BC_Resources::default_listbox_bg = 0;
+VFrame *BC_Resources::default_listbox_expand[5] = { 0, };
+VFrame *BC_Resources::default_listbox_column[3] = { 0, };
+VFrame *BC_Resources::default_listbox_up = 0;
+VFrame *BC_Resources::default_listbox_dn = 0;
+VFrame *BC_Resources::default_pot_images[3] = { 0, };
+VFrame *BC_Resources::default_progress_images[2] = { 0, };
+VFrame *BC_Resources::default_medium_7segment[20] = { 0, };
+
+BC_Resources::BC_Resources()
+{
+ synchronous = 0;
+ vframe_shm = 0;
+ double default_scale = 1.0; // display_size/1000.;
+ char *env = getenv("BC_FONT_SCALE");
+ font_scale = env ? atof(env) : default_scale;
+ if( font_scale <= 0 ) font_scale = 1;
+ init_font_defs(font_scale);
+ env = getenv("BC_ICON_SCALE");
+ icon_scale = env ? atof(env) : default_scale;
+ if( icon_scale <= 0 ) icon_scale = 1;
+
+ id_lock = new Mutex("BC_Resources::id_lock");
+ create_window_lock = new Mutex("BC_Resources::create_window_lock", 1);
+ id = 0;
+ machine_cpus = get_machine_cpus();
+
+ for(int i = 0; i < FILEBOX_HISTORY_SIZE; i++)
+ filebox_history[i].path[0] = 0;
+
+#ifdef HAVE_XFT
+ XftInitFtLibrary();
+#endif
+
+ little_endian = (*(const u_int32_t*)"\01\0\0\0") & 1;
+ wide_encoding = little_endian ? "UTF32LE" : "UTF32BE";
+ use_xvideo = 1;
+