Esempio n. 1
0
 Industry.FX.Font GetFontFor( IrcView.Channel channel )
 {
     return (channel==SelectedChannel) ? Selected
         : channel.IsHighlighted       ? Alerted
         : channel.IsUnread            ? Active
         : Inactive
         ;
 }
Esempio n. 2
0
        static void Main()
        {
            var SettingsPath = Path.Combine( Application.UserAppDataPath, "settings.xml" );
            if (!File.Exists(SettingsPath))
            using ( var writer = File.Create(SettingsPath,Resources.DefaultSettings.Length,FileOptions.SequentialScan) )
            {
                var b = Resources.DefaultSettings;
                writer.Write(b,0,b.Length);
            }
            #if DEBUG
            Process.Start( Application.UserAppDataPath );
            var DebugSettingsPath = Path.Combine( Application.UserAppDataPath, "debug-settings.xml" );
            if ( File.Exists(DebugSettingsPath) ) SettingsPath = DebugSettingsPath;
            #endif
            Settings settings = new Settings(SettingsPath);

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            using ( var view = new IrcView(settings) ) Application.Run(view);
        }
Esempio n. 3
0
 public void Inject( IrcView  view     )
 {
     foreach ( var provider in Providers ) provider.View     = view;
 }
Esempio n. 4
0
 public void OnChannelCreated( IrcView view, IrcView.Channel channel )
 {
     foreach ( var provider in Providers ) provider.OnChannelCreated(view,channel);
 }