コード例 #1
0
        public EditorControl(IStatusBarProvider statusBarProvider)
        {
            if (statusBarProvider == null)
            {
                throw new ArgumentNullException(nameof(statusBarProvider));
            }

            _statusBarProvider = statusBarProvider;
            BreakPoints        = new List <EditorBreakPoint>();

            Font = SystemFonts.MessageBoxFont;

            InitializeComponent();

            _textEditor.SetHighlighting("JavaScript");

            const string consolas = "Consolas";

            var font = new Font(consolas, _textEditor.Font.Size);

            if (font.FontFamily.Name == consolas)
            {
                _textEditor.Font = font;
            }

            _textEditor.ActiveTextAreaControl.Caret.PositionChanged            += Caret_PositionChanged;
            _textEditor.ActiveTextAreaControl.TextArea.IconBarMargin.MouseDown += IconBarMargin_MouseDown;

            SetTabText("New File");
        }
コード例 #2
0
ファイル: LoginForm.cs プロジェクト: pvginkel/JiraQuerier
        public LoginForm(IStatusBarProvider statusBarProvider)
        {
            if (statusBarProvider == null)
                throw new ArgumentNullException("statusBarProvider");

            _statusBarProvider = statusBarProvider;

            InitializeComponent();

            using (var key = Program.BaseKey)
            {
                _userName.Text = (string)key.GetValue("User name");
                _site.Text = (string)key.GetValue("Site");
            #if DEBUG
                _password.Text = (string)key.GetValue("Password");
            #endif
            }
        }
コード例 #3
0
ファイル: JiraApi.cs プロジェクト: pvginkel/JiraQuerier
        public JiraApi(string site, string userName, string password, IStatusBarProvider statusBarProvider)
        {
            if (site == null)
                throw new ArgumentNullException("site");
            if (userName == null)
                throw new ArgumentNullException("userName");
            if (password == null)
                throw new ArgumentNullException("password");
            if (statusBarProvider == null)
                throw new ArgumentNullException("statusBarProvider");

            if (site[site.Length - 1] == '/')
                site = site.Substring(0, site.Length - 1);

            _site = site;
            _userName = userName;
            _password = password;
            _statusBarProvider = statusBarProvider;
        }