ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/main.C
(Generate patch)

Comparing rxvt-unicode/src/main.C (file contents):
Revision 1.300 by root, Sat Jan 19 00:24:53 2008 UTC vs.
Revision 1.301 by ayin, Sat Jan 19 13:00:10 2008 UTC

468 DisplayString (display)); 468 DisplayString (display));
469 rxvt_emergency_cleanup (); 469 rxvt_emergency_cleanup ();
470 _exit (EXIT_FAILURE); 470 _exit (EXIT_FAILURE);
471} 471}
472 472
473/*----------------------------------------------------------------------*/
474void
475rxvt_term::init (int argc, const char *const *argv, stringvec *envv)
476{
477 this->envv = envv;
478
479 SET_R (this);
480 set_locale ("");
481 set_environ (envv); // few things in X do not call setlocale :(
482
483 init_vars ();
484
485 init_secondary ();
486
487 const char **cmd_argv = init_resources (argc, argv);
488
489#ifdef KEYSYM_RESOURCE
490 keyboard->register_done ();
491#endif
492
493#ifdef HAVE_SCROLLBARS
494 if (option (Opt_scrollBar))
495 scrollBar.setIdle (); /* set existence for size calculations */
496#endif
497
498 pty = ptytty::create ();
499
500 create_windows (argc, argv);
501
502 init_xlocale ();
503
504 scr_reset (); // initialize screen
505
506#if 0
507 XSynchronize (dpy, True);
508#endif
509
510#ifdef HAVE_SCROLLBARS
511 if (option (Opt_scrollBar))
512 resize_scrollbar (); /* create and map scrollbar */
513#endif
514#ifdef HAVE_BG_PIXMAP
515 {
516 bgPixmap.set_target (this);
517 bgPixmap.invalidate ();
518
519#ifdef ENABLE_TRANSPARENCY
520 if (option (Opt_transparent))
521 {
522 bgPixmap.set_transparent ();
523
524#ifdef HAVE_AFTERIMAGE
525 if (rs [Rs_blurradius])
526 bgPixmap.set_blur_radius (rs [Rs_blurradius]);
527#endif
528 if (ISSET_PIXCOLOR (Color_tint))
529 bgPixmap.set_tint (pix_colors_focused [Color_tint]);
530
531 if (rs [Rs_shade])
532 bgPixmap.set_shade (rs [Rs_shade]);
533
534 bgPixmap.set_root_pixmap ();
535 XSelectInput (dpy, display->root, PropertyChangeMask);
536 rootwin_ev.start (display, display->root);
537 }
538#endif
539
540#ifdef BG_IMAGE_FROM_FILE
541 if (rs[Rs_backgroundPixmap])
542 {
543 const char *p = rs[Rs_backgroundPixmap];
544
545 if ((p = strchr (p, ';')) != 0)
546 {
547 p++;
548 bgPixmap.set_geometry (p);
549 }
550 else
551 bgPixmap.set_defaultGeometry ();
552
553 if (bgPixmap.set_file (rs[Rs_backgroundPixmap]))
554 if (!bgPixmap.window_position_sensitive ())
555 update_background ();
556 }
557#endif
558 }
559#endif
560
561#if ENABLE_PERL
562 rootwin_ev.start (display, display->root);
563#endif
564
565 set_colorfgbg ();
566
567 init_command (cmd_argv);
568
569 free (cmd_argv);
570
571 if (pty->pty >= 0)
572 pty_ev.start (pty->pty, ev::READ);
573
574 HOOK_INVOKE ((this, HOOK_START, DT_END));
575
576#if ENABLE_XEMBED
577 if (rs[Rs_embed])
578 {
579 long info[2] = { 0, XEMBED_MAPPED };
580
581 XChangeProperty (dpy, parent[0], xa[XA_XEMBED_INFO], xa[XA_XEMBED_INFO],
582 32, PropModeReplace, (unsigned char *)&info, 2);
583 }
584#endif
585
586 XMapWindow (dpy, vt);
587 XMapWindow (dpy, parent[0]);
588
589 refresh_check ();
590}
591
592static struct sig_handlers 473static struct sig_handlers
593{ 474{
594 ev::sig sw_term, sw_int; 475 ev::sig sw_term, sw_int;
595 476
596 /* 477 /*

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines