{"id":14986267,"url":"https://github.com/jakesee/ganttchart","last_synced_at":"2025-04-13T06:35:34.937Z","repository":{"id":55064286,"uuid":"99235364","full_name":"jakesee/ganttchart","owner":"jakesee","description":"The Winforms Gantt Chart is the .NET Winforms control originally hosted on CodePlex (http://ganttchart.codeplex.com)","archived":false,"fork":false,"pushed_at":"2022-08-09T10:42:35.000Z","size":182,"stargazers_count":191,"open_issues_count":13,"forks_count":81,"subscribers_count":24,"default_branch":"master","last_synced_at":"2025-03-24T10:54:05.455Z","etag":null,"topics":["chart","dotnet","dotnet-framework","gantt","gantt-chart","winforms","winforms-controls"],"latest_commit_sha":null,"homepage":"https://jakesee.sg/net-c-winforms-gantt-chart-control/","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jakesee.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-03T13:26:59.000Z","updated_at":"2025-03-10T06:38:54.000Z","dependencies_parsed_at":"2022-08-14T10:50:17.894Z","dependency_job_id":null,"html_url":"https://github.com/jakesee/ganttchart","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jakesee%2Fganttchart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jakesee%2Fganttchart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jakesee%2Fganttchart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jakesee%2Fganttchart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jakesee","download_url":"https://codeload.github.com/jakesee/ganttchart/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248675159,"owners_count":21143763,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chart","dotnet","dotnet-framework","gantt","gantt-chart","winforms","winforms-controls"],"created_at":"2024-09-24T14:12:37.206Z","updated_at":"2025-04-13T06:35:34.904Z","avatar_url":"https://github.com/jakesee.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"![](http://img.shields.io/badge/project%20status-stable%20and%20respond%20to%20queries-green.svg?style=flat)  ![](http://img.shields.io/badge/license-MIT-red.svg?style=flat)\n\n# .NET C# Winforms Gantt Chart Control\nThis .NET class library project provides a C# Winforms UserControl that draws a gantt chart using native GDI+.\n\n## Getting Started\nThe project is written with Microsoft Visual Studio 2017, simply download the latest source code from the master branch and build the library with the IDE.\n\n### Prerequisites\nNo pre-requisites other than the .NET Framework.\n\n### Installing\nThe project builds into a class library with example applications.\n\n## Running the tests\nThe source code includes a test project GanttChartTests which you can load and run within Microsoft Visual Studio 2017 from the test menu.\n\n## Features\n* Support time units Weeks, Days (default), Hours out-of-the-box, can be modified to support other time resolutions.\n* Single tasks, grouped tasks, precedent/dependant tasks, split tasks, tagged resources \n* Printing respects page margin, orientation and multiple pages per page\n* Percentage complete property for each task\n* Various mouse events for customising UI experience directly on the chart.\n* Comes with default mouse commands that can be overridden through inheritance.\n* Determines critical path and slack\n\n# Documentation\nJump directly to the [doxygen documentation](http://www.jakesee.com/docs/ganttchart), or visit my [blog](http://www.jakesee.com/net-c-winforms-gantt-chart-control/) for more information. (Please make sure you are reading the updated versions while I try to keep up, thanks.)\n\n![](http://www.jakesee.com/codeplex/ganttchart.jpg)\n\n## Basic Usage\n### Create Chart and Adding Tasks\n\n\tpublic Form1()\n\t{\n\t    InitializeComponents();\n\t    var manager = new ProjectManager();\n\t    var task = new Task() { Name = \"Hello World\" };\n\t    manager.Add(task);\n\t    var chart = new Chart();\n\t    chart.Init(manage);\n\t    \n\t    this.Controls.Add(chart);\n\n\t    this.AutoScroll = true; // this is no longer required\n\t}\n\n\n### Common Task Manipulation\nYou can manipulate the task through code using various methods in the ProjectManager:\n\n\n\t// Set task durations\n\t_mManager.SetDuration(wake, 3);\n\t// Give the Tasks some organisation, setting group and\n\t// precedents e.g. make \"wake\" task a subtask under \"work\"\n\t_mManager.Group(work, wake);\n\t// Setting task dependencies e.g. make \"wake\" task a precedent of \"brush teeth\" task\n\t_mManager.Relate(wake, teeth);\n\t// Assigning Resources e.g. add \"jake\" resource to \"wake\" task\n\t_mManager.Assign(wake, jake);\n\t// splitting a tasks e.g. split the \"pack up\" task into 2 new tasks\n\t_mManager.Split(pack, new MyTask(_mManager), new MyTask(_mManager), 2);\n\t// set some tooltips to show the resources in each task\n\t// e.g. set a tooltip on the \"wake\" task\n\t_mChart.SetToolTip(wake, string.Join(\", \", _mManager.ResourcesOf(wake).Select(x =\u003e (x as MyResource).Name)));\n\n### Custom Task Data: Different colors for every tasks\nYou can change the default task appearance for all task, or as in here change individual task color as a demo for adding custom business data to tasks.\n\n\tpublic partial class ExampleSimple : Form\n\t{\n\t  ProjectManager _mProject;\n\t  public ExampleSimple()\n\t  {\n\t    InitializeComponent();\n\t    _mProject = new ProjectManager();\n\t    _mProject.Add(new Task() { Name = \"New Task\" });\n\t    _mProject.Add(new ColoredTask() { Name = \"Purple Task\", Color = Color.Purple });\n\t    _mProject.Add(new ColoredTask() { Name = \"Gold Task\", Color = Color.Gold });\n\t    _mChart.Init(_mProject);\n\t    // Custom behavior on paint task\n\t    _mChart.PaintTask += (s, e) =\u003e\n\t    {\n\t        ColoredTask ctask = e.Task as ColoredTask;\n\t        if (ctask != null)\n\t        {\n\t            var format = new TaskFormat();\n\t            format = e.Format;\n\t            format.BackFill = new SolidBrush(ctask.Color);\n\t            e.Format = format;\n\t        }\n\t    };\n\t\t\t\n\t    // Grab custom data for tasks\n\t    _mChart.TaskSelected += (s, e) =\u003e\n\t    {\n\t        ColoredTask ctask = e.Task as ColoredTask;\n\t        if (ctask != null)\n\t        {\n\t            MessageBox.Show(\"Selected \" + ctask.Color.ToString());\n\t        }\n\t    };\n\t  }\n\t}\n\n\t// Custom task with business data\n\tpublic class ColoredTask : Task\n\t{\n\t    public ColoredTask() : base() {}\n\t    public Color Color { get; set; }\n\t}\n## License\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjakesee%2Fganttchart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjakesee%2Fganttchart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjakesee%2Fganttchart/lists"}