Jump to content
How to Install Plugins ×

BoltBait's Charts and Graphs Plugin v0.2 Updated Jun 22 2019


BoltBait

Recommended Posts

BoltBait's Charts and Graphs Plugin v0.2 (Prerelease, Test Build)

 

I quickly slapped this together because of this request.  (There are probably issues.  Give me feedback and I'll see if I can fix them.)

 

It looks like this:

 

ChartUI.png

 

You'll find it in the Effects > Render > Chart menu.

 

Instructions:

 

First, choose your chart type.  Then, click the "Enter Data" button to enter your chart data.  On the data entry screen, you can click the colors to change them and you can right-click on column titles to change those.  Finally, tinker with your other options and click the OK button to finalize your chart image.

 

Important:  Remember to click the "Save Data" button to save a copy of your chart data to an xml file.  This file can then be used later when clicking the "Load Data" button to restore your chart options and data.  This is the only way to save the format of your chart if you wish to come back later to make tweaks.  Once you click OK, your chart is now a graphic and can't be edited.

 

 

Limitations:

 

This chart control is not designed to work with selections.  I might add that later if users think it is important.  The resulting chart is scaled to the size of your canvas.  So, before running, set your canvas size to the size of graph you want and press Ctrl+D to close any selection you might have active.

 

 

Download:

 

Click the button to download the zip file which includes an installer.  Download the zip file to your desktop, unzip both files to your desktop and run the installer.  If successful, you can delete all the new files from your desktop.

 

Download

Paint.NET v4.3+

 

If you're using Paint.NET v4.3 (or higher), download the updated plugin here:

 

https://forums.getpaint.net/topic/114530-boltbaits-charts-and-graphs-plugin-v02-updated-jun-22-2019/?tab=comments#comment-586630

 

Once all the bugs are worked out, I'll be adding this to my plugin pack.

 

 

Source code:

 

Spoiler

Hahaha. No.

 

I can't take credit for all of this... lots of it was written by @toe_head2001 and Microsoft for another project... but, I did get it working for Paint.NET. 

 

  • Like 5
  • Upvote 1
Link to comment
Share on other sites

  • BoltBait changed the title to BoltBait's Charting Control v0.1

Very nice plugin! Thanks.

 

First crash: Enter some data and click on Tuesday.

 

Exception details:
System.ArgumentException: Object must be of type Double.
   at System.Double.CompareTo(Object value)
   at System.Windows.Forms.DataGridViewRowCollection.RowComparer.CompareObjects(Object value1, Object value2, Int32 rowIndex1, Int32 rowIndex2)
   at System.Windows.Forms.DataGridViewRowCollection.RowArrayList.Pivot(Int32 left, Int32 center, Int32 right)
   at System.Windows.Forms.DataGridViewRowCollection.RowArrayList.CustomQuickSort(Int32 left, Int32 right)
   at System.Windows.Forms.DataGridViewRowCollection.Sort(IComparer customComparer, Boolean ascending)
   at System.Windows.Forms.DataGridView.SortInternal(IComparer comparer, DataGridViewColumn dataGridViewColumn, ListSortDirection direction)
   at System.Windows.Forms.DataGridView.OnColumnHeaderMouseClick(DataGridViewCellMouseEventArgs e)
   at System.Windows.Forms.DataGridView.OnMouseClick(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
 

Link to comment
Share on other sites

I’ll prevent that error in the next build. But, I’m traveling for the next few days. At least you know how to avoid the error in the mean time. 

 

EDIT: I just started digging into the code on this issue... ugh... this might take a while. :(  I will probably take out the preview on the data entry screen. 

Link to comment
Share on other sites

  • BoltBait changed the title to BoltBait's Charts and Graphs Plugin v0.2 Updated Jun 22 2019
  • 2 years later...

Looks like this needs an update for .NET 5. You can use the System.Windows.Forms.DataVisualization nuget package, and then install its DLL and the BBChart.dll to a folder inside Effects. 

 

  • Thanks 1

The Paint.NET Blog: https://blog.getpaint.net/

Donations are always appreciated! https://www.getpaint.net/donate.html

forumSig_bmwE60.jpg

Link to comment
Share on other sites

  • 1 month later...
On 8/9/2021 at 9:15 AM, Rick Brewster said:

Looks like this needs an update for .NET 5.

 

Here's the update for .NET 5 and Paint.NET v4.3:

 

BBChart11.zip

 

Unzip this file to your desktop, then move the BBChart directory (including the 3 dll files inside) to your Paint.NET Effects directory.

 

  • Like 2
  • Upvote 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...