本文整理汇总了C#中System.Windows.Forms.TabControl类的典型用法代码示例。如果您正苦于以下问题:C# TabControl类的具体用法?C# TabControl怎么用?C# TabControl使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
TabControl类属于System.Windows.Forms命名空间,在下文中一共展示了TabControl类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: Attach
public static void Attach (Panel ParentArg)
{ Tabs = new TabControl () ;
Tabs.Parent = ParentArg ;
Tabs.Dock = DockStyle.Fill ;
Tabs.Multiline = true ;
}
开发者ID:kcb146,项目名称:editor,代码行数:7,代码来源:TabManager.CS
示例2: Attach
public override void Attach(TabControl aFrame, string name)
{
base.Attach(aFrame, project.Name);
IDEApplication.Instance.Editors.Insert(0, this);
redCodeProjectBindingSource.DataSource = project;
ActivateControl();
}
开发者ID:pavelsavara,项目名称:nMars,代码行数:7,代码来源:ProjectEditor.cs
示例3: InitializeComponent
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.m_ButtonPanel = new System.Windows.Forms.Panel();
this.m_TabControl = new System.Windows.Forms.TabControl();
this.SuspendLayout();
//
// m_ButtonPanel
//
this.m_ButtonPanel.Dock = System.Windows.Forms.DockStyle.Bottom;
this.m_ButtonPanel.Location = new System.Drawing.Point(0, 218);
this.m_ButtonPanel.Name = "m_ButtonPanel";
this.m_ButtonPanel.Size = new System.Drawing.Size(272, 40);
this.m_ButtonPanel.TabIndex = 0;
//
// m_TabControl
//
this.m_TabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.m_TabControl.Location = new System.Drawing.Point(4, 8);
this.m_TabControl.Name = "m_TabControl";
this.m_TabControl.SelectedIndex = 0;
this.m_TabControl.Size = new System.Drawing.Size(264, 200);
this.m_TabControl.TabIndex = 1;
//
// TabbedDialogView
//
this.Controls.Add(this.m_TabControl);
this.Controls.Add(this.m_ButtonPanel);
this.Name = "TabbedDialogView";
this.Size = new System.Drawing.Size(272, 258);
this.Load += new System.EventHandler(this.EhView_Load);
this.ResumeLayout(false);
}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:39,代码来源:TabbedElementControl.cs
示例4: NewFile
public static void NewFile(TabControl tabcontrol)
{
int sotab = tabcontrol.TabCount;
//MessageBox.Show(sotab.ToString());
int i=0;
for (i = 0; i < sotab; )
{
int dem = 0;
foreach (TabPage page in tabcontrol.TabPages)
{
if (page.Text == "New File" + i.ToString())
{
dem++;
}
}
if (dem == 0)
break;
else i++;
}
//if (i < sotab)
{
TabPage newpage = new TabPage();
newpage.Text = "New File" + i.ToString();
RichTextBox newrtb = new RichTextBox();
newrtb.Dock = DockStyle.Fill;
newrtb.WordWrap = false;
newpage.Controls.Add(newrtb);
tabcontrol.TabPages.Add(newpage);
tabcontrol.SelectedTab = newpage;
}
}
开发者ID:hungnv0789,项目名称:vhtm,代码行数:34,代码来源:BasicCommand.cs
示例5: TabDragDrop
public TabDragDrop(TabControl tabControl)
{
tabControl1 = tabControl;
tabControl1.AllowDrop = true;
this.tabControl1.DragOver += new System.Windows.Forms.DragEventHandler(this.tabControl1_DragOver);
this.tabControl1.MouseMove += new System.Windows.Forms.MouseEventHandler(this.tabControl1_MouseMove);
}
开发者ID:450640526,项目名称:HtmExplorer,代码行数:7,代码来源:TabDragDrop.cs
示例6: monitor
public monitor(DynamicNode n)
{
//MessageBox.Show(n.Owner.ToString());
props = n.GetType().GetProperties();
this.Text = "Resource monitor - " + n.ToString();
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow;
this.ClientSize = new System.Drawing.Size(480, 640);
this.StartPosition = FormStartPosition.Manual;
//this.Location = new Point(this.Parent
// TABS
tc = new TabControl();
tc.Dock = DockStyle.Fill;
tp_props = new TabPage();
tc.Controls.AddRange(new Control[] { tp_props });
// Datagrid for properties
pg_props = new PropertyGrid();
pg_props.SelectedObject = n;
pg_props.Dock = DockStyle.Fill;
tp_props.Controls.Add(pg_props);
t = new Timer();
t.Interval = 100;
t.Tick += delegate(object sender, EventArgs e) { pg_props.Refresh(); };
t.Start();
this.Controls.Add(tc);
}
开发者ID:r-bel,项目名称:glorg2,代码行数:31,代码来源:ResourceMonitor.cs
示例7: PutControls
public void PutControls(List<IExtension> extensions, OMenuItems menu, TabControl tabControl, int clientId, int contractId)
{
if (extensions != null)
{
foreach (var extension in extensions)
{
if (extension.MainMenu == menu)
{
TabPage tabPageExtension = new TabPage();
tabPageExtension.SuspendLayout();
tabPageExtension.Name = extension.ExtensionName;
tabPageExtension.Text = extension.ExtensionName;
tabPageExtension.UseVisualStyleBackColor = true;
extension.ClientId = clientId;
extension.ContractId = contractId;
UserControl control = (UserControl)extension;
control.Dock = DockStyle.Fill;
tabPageExtension.Controls.Add(control);
tabPageExtension.ResumeLayout(false);
tabControl.TabPages.Add(tabPageExtension);
}
}
}
}
开发者ID:Ramazanov,项目名称:FomsNet,代码行数:25,代码来源:Extensions.cs
示例8: MakeTabPagesMenuGrey
private void MakeTabPagesMenuGrey(TabControl tbc)
{
foreach (TabPage page in tbc.TabPages)
{
page.BackColor = SystemColors.Menu;
}
}
开发者ID:hbheiner,项目名称:cuda-profit-calc,代码行数:7,代码来源:ProfitCalc.cs
示例9: MainController
private MainController(ActivitiesController activitiesController, RichTextBox txtPrompting,
TabControl tabControl) {
_activitiesController = activitiesController;
_txtPrompting = txtPrompting;
_tabControl = tabControl;
InitActivitiesList(_activitiesController.ServiceProvider);
}
开发者ID:satr,项目名称:rvslite,代码行数:7,代码来源:MainController.cs
示例10: MainForm
public MainForm()
{
InitializeComponent();
_treeViewHandler = new TreeViewHandler(treeView1, treeMenu);
TabControl = tabControl1;
ListAnalysis = listAnalysis;
ListAnalysis.Columns[0].Width = -1;
LblAnalysis = lblAnalysis;
DgBody = dgBody;
DgVariables = dgVariables;
RtbILSpy = rtbILSpy;
TreeView = treeView1;
ToolStrip = toolStrip1;
InstructionMenuStrip = instructionMenu;
VariableMenu = variableMenu;
ExceptionHandlerMenu = exceptionHandlerMenu;
TreeMenuStrip = treeMenu;
txtMagicRegex.Text = Settings.Default.MagicRegex;
InitializeBody();
cbSearchType.SelectedIndex = 0;
}
开发者ID:AssassinUKG,项目名称:dnEditor,代码行数:28,代码来源:MainForm.cs
示例11: MultiClipboard
public MultiClipboard(TabControl control)
{
_maxCountofBuffers = 4;
_currentIndex = 0;
_currentCountofBuffers = 0;
_control = control;
}
开发者ID:BachinskiyBogdan,项目名称:lab_1_comp_architechture,代码行数:7,代码来源:MultiClipboard.cs
示例12: DashGlobal
public DashGlobal(
EventHandler<TextChangedEventArgs> textAreaTextChanged,
EventHandler<TextChangedEventArgs> textAreaTextChangedDelayed,
KeyEventHandler textAreaKeyUp,
EventHandler textAreaSelectionChangedDelayed,
DragEventHandler textAreaDragDrop,
DragEventHandler textAreaDragEnter,
TabControl mainTabControl,
AutocompleteMenu armaSense,
Main mainWindow)
{
EditorHelper = new EditorHelper(
textAreaTextChanged,
textAreaTextChangedDelayed,
textAreaKeyUp,
textAreaSelectionChangedDelayed,
textAreaDragDrop,
textAreaDragEnter,
mainTabControl,
armaSense,
this);
TabsHelper = new TabsHelper(
textAreaTextChanged,
textAreaSelectionChangedDelayed,
mainTabControl,
this);
FilesHelper = new FilesHelper(this);
SettingsHelper = new SettingsHelper();
MainWindow = mainWindow;
}
开发者ID:alandoherty,项目名称:dash-core,代码行数:33,代码来源:DashGlobal.cs
示例13: Custom
public Custom(frmMain Main, Graphics g, TabControl TabControlMain, TabControl TabControlProperties)
{
this.Main = Main;
this.g = g;
this.TabControlMain = TabControlMain;
this.TabControlProperties = TabControlProperties;
}
开发者ID:SnakeSolidNL,项目名称:tools,代码行数:7,代码来源:Custom.cs
示例14: Main_frm
public Main_frm()
{
InitializeComponent();
LauncherHelper.CardManager = new CardDatabase.CardsManager();
LauncherHelper.CardManager.Init();
char[] version = Program.Version.ToCharArray();
this.Text = Program.LanguageManager.Translation.MainFormTitle + " v" + version[0] + "." + version[1] + "." + version[2];
TabPage FileManager = new TabPage(){ Name = "File Manager", Text = Program.LanguageManager.Translation.MainFileManagerTab};
TabControl FileControl = new TabControl();
FileControl.Dock = DockStyle.Fill;
TabPage decktab = new TabPage() {Name = "Decks",Text =Program.LanguageManager.Translation.MainFileDeckTab};
decktab.Controls.Add(new FileManager_frm("Decks", Program.Config.LauncherDir + "deck/", ".ydk"));
TabPage replaytab = new TabPage() { Name = "Replays", Text = Program.LanguageManager.Translation.MainFileReplayTab };
replaytab.Controls.Add(new FileManager_frm("Replays", Program.Config.LauncherDir + "replay/", ".yrp"));
FileControl.TabPages.AddRange(new TabPage[] { decktab, replaytab });
FileManager.Controls.Add(FileControl);
TabPage ServerTab = new TabPage() { Text = Program.Config.ServerName, Name = Program.Config.ServerName };
ServerTab.Controls.Add(new ServerInterface_frm(Program.Config.ServerName));
TabPage CustomizeTab = new TabPage() { Text = "Customize", Name = Program.LanguageManager.Translation.MainCustomizeTab};
CustomizeTab.Controls.Add(new Customize_frm());
TabPage AboutTab = new TabPage() { Text = "About", Name = Program.LanguageManager.Translation.MainAboutTab};
AboutTab.Controls.Add(new About_frm());
TabPage ChatTab = new TabPage() { Text = "Chat (Beta)", Name = Program.LanguageManager.Translation.MainChatTab};
ChatTab.Controls.Add(new Chat_frm());
if (Program.UserInfo.Rank > 0)
{
ServerControl.TabPages.AddRange(new TabPage[] { ServerTab,
ChatTab,
CreateBrowserWindow("Tournament Room",Program.LanguageManager.Translation.MainTornyTab),
CreateBrowserWindow("Youtube",Program.LanguageManager.Translation.MainYoutubeTab),
FileManager, CustomizeTab, AboutTab });
}
else
{
ServerControl.TabPages.AddRange(new TabPage[] { ServerTab,
ChatTab,
CreateBrowserWindow("Tournament Room",Program.LanguageManager.Translation.MainTornyTab),
CreateBrowserWindow("Youtube",Program.LanguageManager.Translation.MainYoutubeTab),
FileManager, CustomizeTab, AboutTab });
}
Program.ServerConnection.ServerMessage += new NetClient.ServerResponse(ServerMessage);
ConnectionCheck.Tick += new EventHandler(CheckConnection);
ServerControl.SelectedIndexChanged += new EventHandler(NavigateOnClick);
LauncherHelper.LoadBanlist();
}
开发者ID:Elfoman,项目名称:DevProLauncher,代码行数:60,代码来源:Main_frm.cs
示例15: EditorHelper
private string[] snippets = { }; //{ "diag_log \"\";", "for \"_i\" from 1 to 10 do { debugLog _i; };", "call compile preprocessFileLine Numbers \"\";" };
#endregion Fields
#region Constructors
public EditorHelper(
EventHandler<TextChangedEventArgs> textAreaTextChanged,
EventHandler<TextChangedEventArgs> textAreaTextChangedDelayed,
KeyEventHandler textAreaKeyUp,
EventHandler textAreaSelectionChangedDelayed,
DragEventHandler textAreaDragDrop,
DragEventHandler textAreaDragEnter,
TabControl mainTabControl,
AutocompleteMenu armaSense,
DashGlobal dashGlobal)
{
TextAreaTextChanged = textAreaTextChanged;
TextAreaTextChangedDelayed = textAreaTextChangedDelayed;
TextAreaKeyUp = textAreaKeyUp;
TextAreaSelectionChangedDelayed = textAreaSelectionChangedDelayed;
TextAreaDragDrop = textAreaDragDrop;
TextAreaDragEnter = textAreaDragEnter;
MainTabControl = mainTabControl;
ArmaSense = armaSense;
DashGlobal = dashGlobal;
ArmaListItemsCount = 0;
ArmaSenseKeywords = new List<AutocompleteItem>();
foreach (var item in keywordList)
{
ArmaSenseKeywords.Add(new AutocompleteItem(item) { ImageIndex = 0, ToolTipTitle = "Arma Script Command", ToolTipText = item });
}
}
开发者ID:alandoherty,项目名称:dash-core,代码行数:36,代码来源:EditorHelper.cs
示例16: Setup
public void Setup()
{
this.tabCtrl = new TabControl();
this.mr = new MockRepository();
this.pane = mr.Stub<IWindowPane>();
this.services = mr.Stub<IServiceProvider>();
}
开发者ID:gitter-badger,项目名称:reko,代码行数:7,代码来源:TabControlHostTests.cs
示例17: SetTab
public void SetTab(TabControl tab)
{
this.tab = tab;
tab.Selected +=new TabControlEventHandler(tab_Selected);
uxPrevious.Visible = false;
}
开发者ID:shoaib-ijaz,项目名称:geosoft,代码行数:7,代码来源:NextPrevious.cs
示例18: SetupForm
private void SetupForm()
{
SuspendLayout();
Controls.Clear();
tabControl = getNewTabControl();
tabControl.SuspendLayout();
for (int i = 0; i < tabCaptions.Length; i++)
{
textboxes[i] = getNewTextBox();
tabPages[i] = getNewTabPage(textboxes[i], tabCaptions[i]);
tabControl.Controls.Add(tabPages[i]);
}
Controls.Add(tabControl);
this.AutoScaleDimensions = new SizeF(96F, 96F);
this.AutoScaleMode = AutoScaleMode.Dpi;
this.ClientSize = new Size(624, 442);
this.FormBorderStyle = FormBorderStyle.FixedDialog;
this.MaximizeBox = false;
this.MinimizeBox = false;
this.StartPosition = FormStartPosition.CenterParent;
this.Text = "Thanks to...";
this.ResumeLayout(false);
}
开发者ID:Carbenium,项目名称:gitextensions,代码行数:30,代码来源:FormContributors.cs
示例19: TabChangedBinding
public TabChangedBinding(TabControl exitableTabControl, ICommand command, Func<object> commandParameterCallback)
: base(exitableTabControl, command)
{
_tabControl = exitableTabControl;
_commandParameterCallback = commandParameterCallback;
_tabControl.SelectedIndexChanged += TabControlSelectedIndexChanged;
}
开发者ID:Blind-Striker,项目名称:supremefiction,代码行数:7,代码来源:TabChangedBinding.cs
示例20: GetControl
public Control GetControl()
{
tab = new TabControl { Dock = DockStyle.Fill };
Control bookmarkedRow = null; // the row we want to start at
foreach (var ecl in _file.eclDumps)
{
var page = new TabPage(ecl._blockName);
Panel codePanel = (Panel) ViewerHelper.CreatePanel();
codePanel.Name = "codepanel";
codePanel.Tag = ecl;
//page.AutoScroll = true;
page.Controls.Add(codePanel);
// fill the code panel with the decoded ecl code
bookmarkedRow = FillECLCodePanel(page);
// add a search bar and 'select all' button to the top of the ecl listing
var selectAll = ViewerHelper.CreateButton();
selectAll.Text = "Copy to clipboard";
selectAll.MouseClick += selectAllRows;
selectAll.Dock = DockStyle.Right;
var findNext = ViewerHelper.CreateButton();
findNext.Text = "find next";
findNext.MouseClick += searchEclNext;
findNext.Dock = DockStyle.Right;
TextBox headerText = (TextBox) ViewerHelper.CreateTextBox();
headerText.ReadOnly = false;
headerText.Text = "Type text to find";
headerText.TextChanged += searchEcl;
headerText.KeyDown += searchEclKeyPressed;
headerText.Dock = DockStyle.Fill;
var row1 = ViewerHelper.CreateRow();
page.Controls.Add(row1);
row1.Controls.Add(headerText);
row1.Controls.Add(findNext);
row1.Controls.Add(selectAll);
tab.TabPages.Add(page);
if (page.Text == ChangeFileEventArgs.currentDaxId.ToString())
{
tab.SelectedTab = page;
codePanel.ScrollControlIntoView(bookmarkedRow);
}
}
var stringPage = new TabPage("ECL Text");
stringPage.AutoScroll = true;
var control = ViewerHelper.CreateTextBoxMultiline();
control.Text = _file.ToString();
stringPage.Controls.Add(control);
tab.TabPages.Add(stringPage);
tab.Selected += ECLTabControlLoadSelected;
tab.Deselected += ECLTabControlUnloadDeselected;
return tab;
}
开发者ID:bsimser,项目名称:goldbox,代码行数:60,代码来源:EclFileViewer.cs
注:本文中的System.Windows.Forms.TabControl类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论