Pratyush Posted March 12, 2018 Share Posted March 12, 2018 20 hours ago, BoltBait said: CodeLab will insert a plugin browser image for you. What is plugin browser ? what does it do? Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted March 12, 2018 Share Posted March 12, 2018 2 hours ago, Pratyush said: What is plugin browser ? what does it do? https://forums.getpaint.net/topic/110458-the-plugin-browser-v1210-jan-9-2018/ Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
Pratyush Posted March 14, 2018 Share Posted March 14, 2018 @toe_head2001 Why do you need visual studio for plugin browser(As Madjik said)? Doesn't plugin browser works for all created plugins? Quote Link to comment Share on other sites More sharing options...
MadJik Posted March 14, 2018 Share Posted March 14, 2018 VS allows to -add a picture 200x150 to illustrate the effect -use multi language labels -use multi language keywords Quote My DeviantArt | My Pictorium | My Plugins | Donate via Paypal Link to comment Share on other sites More sharing options...
BoltBait Posted March 14, 2018 Share Posted March 14, 2018 3 hours ago, MadJik said: VS allows to -add a picture 200x150 to illustrate the effect As I said before, CodeLab has this capability. Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
Pratyush Posted March 25, 2018 Share Posted March 25, 2018 Hi, can tabs be supported in Codelab? if there would be 3 or 4 tabs, it would be quite helpful in copying and testing different versions together. Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted March 26, 2018 Share Posted March 26, 2018 17 hours ago, Pratyush said: ... can tabs be supported in Codelab? Yes, tabs could be supported in CodeLab. You might be the only person who would use such a feature though. Personally, I have no interest in putting in the work to add tabs. It really wouldn't be difficult to implement though. It would mostly consist of making sure all the user interface buttons get mapped to the active tab. Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
BoltBait Posted March 26, 2018 Share Posted March 26, 2018 47 minutes ago, toe_head2001 said: Personally, I have no interest in putting in the work to add tabs. Me either. Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
xod Posted June 16, 2018 Share Posted June 16, 2018 (edited) CodeLab crashes if we use the slash character in the UI. Same for any mathematical symbol. Exception details: System.FormatException: Input string was not in a correct format. at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) at PaintDotNet.Effects.UIBuilder.ControlType_SelectedIndexChanged(Object sender, EventArgs e) at System.Windows.Forms.ComboBox.OnSelectedIndexChanged(EventArgs e) at System.Windows.Forms.ComboBox.set_SelectedIndex(Int32 value) at System.Windows.Forms.ComboBox.set_Text(String value) at PaintDotNet.Effects.UIBuilder.ControlListView_SelectedIndexChanged(Object sender, EventArgs e) at System.Windows.Forms.ListView.OnSelectedIndexChanged(EventArgs e) at System.Windows.Forms.ListView.WmReflectNotify(Message& m) at System.Windows.Forms.ListView.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) Edited June 16, 2018 by xod Added image. Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted June 16, 2018 Share Posted June 16, 2018 3 hours ago, xod said: CodeLab crashes if we use the slash character in the UI. Same for any mathematical symbol. Slashes seem to work fine. The crash is actually caused by the 0.6 in the Default box. When switching to the Checkbox, CodeLab attempts to Parse the 0.6 as an integer. Fixed for the next release: if (int.TryParse(ControlDef.Text, out int result) && result > 0) 1 Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
toe_head2001 Posted July 25, 2018 Share Posted July 25, 2018 Tired of having to create a Visual Studio project and configure it ... every time you export from plugin from CodeLab? Me too, so I automated it all! ? 1 5 Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted July 25, 2018 Share Posted July 25, 2018 What a great idea! ? Quote ebook: Mastering Paint.NET | resources: Plugin Index | Stereogram Tut | proud supporter of Codelab plugins: EER's Plugin Pack | Planetoid | StickMan | WhichSymbol+ | Dr Scott's Markup Renderer | CSV Filetype | dwarf horde plugins: Plugin Browser | ShapeMaker Link to comment Share on other sites More sharing options...
MadJik Posted July 25, 2018 Share Posted July 25, 2018 Good idea. How could I test it? Quote My DeviantArt | My Pictorium | My Plugins | Donate via Paypal Link to comment Share on other sites More sharing options...
toe_head2001 Posted July 27, 2018 Share Posted July 27, 2018 On 3/25/2018 at 6:22 AM, Pratyush said: Hi, can tabs be supported in Codelab? if there would be 3 or 4 tabs, it would be quite helpful in copying and testing different versions together. This would be even easier than I original thought. A whole lot easier. Scintilla can actually handle multiple documents natively, so we wouldn't even need to spawn additional editor controls (which was my main concern). Therefore, I am reconsidering adding tabs, as my older assessment of "not worth the effort" is no longer accurate. 2 1 Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
xod Posted July 27, 2018 Share Posted July 27, 2018 This would be an extremely useful improvement. 1 Quote Link to comment Share on other sites More sharing options...
Pratyush Posted July 31, 2018 Share Posted July 31, 2018 On 7/27/2018 at 10:11 PM, xod said: This would be an extremely useful improvement. I second that. ? Quote Link to comment Share on other sites More sharing options...
BoltBait Posted September 6, 2018 Share Posted September 6, 2018 CodeLab 4.0 Released This is only for Paint.NET 4.1+! Big update today... Changes: ▪ Editor has tabs and can edit more than one file at a time. (toe_head2001) ▪ Generate VS Project function on Build screen. (toe_head2001) ▪ Separate Save and Save As functions. (toe_head2001) ▪ The autocomplete function now does matching initials. (toe_head2001) ▪ Indicator Map (Ctrl+M) now integrated with scroll bar. (toe_head2001) ▪ Building to DLL now saves to Desktop in a ZIP file all ready for posting. (BoltBait) ▪ Install.BAT files now work for both the Classic and Store versions of PdN. (BoltBait) ▪ Colorwheel control now has Alpha style option. (BoltBait) ▪ Colorwheel control reset button can now be hidden. (BoltBait) ▪ Filename control added. (BoltBait) ▪ File>New templates have a "non-looping" style for GDI+ plugins. (BoltBait) Grab the CodeLab DLL here: http://www.boltbait.com/pdn/CodeLab/ Screenshot(s): Check out this new UI feature, tabs: Indicator Map scrollbar How to access the new Colorwheel with Alpha: How to generate a script for using GDI+ commands: Example Scripts: Here is a CodeLab script for using the new FilenameControl: Spoiler // Name: Fill from file // Author: BoltBait #region UICode FilenameControl Amount1 = @""; // Open Image|jpg|png|gif|bmp #endregion Surface wrk = null; protected override void OnDispose(bool disposing) { if (wrk != null) wrk.Dispose(); wrk = null; base.OnDispose(disposing); } void PreRender(Surface dst, Surface src) { if (wrk == null) { wrk = new Surface(src.Size); } try { // Use your FilenameControl to load an image for use wrk = Surface.CopyFromBitmap((Bitmap)Bitmap.FromFile(Amount1)); } catch { wrk.Clear(ColorBgra.Transparent); } } void Render(Surface dst, Surface src, Rectangle rect) { for (int y = rect.Top; y < rect.Bottom; y++) { if (IsCancelRequested) return; for (int x = rect.Left; x < rect.Right; x++) { ColorBgra CurrentPixel = wrk.GetBilinearSampleWrapped(x,y); dst[x,y] = CurrentPixel; } } } Notice in the definition of the control, in the comment we have the title of the control followed by the file types allowed: FilenameControl Amount1 = @""; // Open Image|jpg|png|gif|bmp So, in this example, the prompt will be "Open Image" and the allowed file types will be .jpg, .png, .gif, and .bmp. For tinkering inside of CodeLab, between the quotes you can place a path to a file. (Notice that the @ sign before the first quote allows you to use the backslash character "\" without escaping it (doubling them). Here is an example GDI+ script: Spoiler On the File > New (Templates) screen, you can now choose a looping style of "None". This will generate a script like this: // Name: GDI+ Example // Author: BoltBait #region UICode #endregion // Working surface Surface wrk = null; // Setup for using Normal blend op private BinaryPixelOp normalOp = LayerBlendModeUtil.CreateCompositionOp(LayerBlendMode.Normal); protected override void OnDispose(bool disposing) { // Release any surfaces or effects you've created. if (wrk != null) wrk.Dispose(); wrk = null; base.OnDispose(disposing); } void PreRender(Surface dst, Surface src) { if (wrk == null) { wrk = new Surface(src.Size); } wrk.Clear(ColorBgra.Transparent); } // Here is the main render loop function void Render(Surface dst, Surface src, Rectangle rect) { using (Graphics g = new RenderArgs(wrk).Graphics) using (Region gClipRegion = new Region(rect)) using (Pen pen = new Pen(ColorBgra.Black, 1)) using (GraphicsPath path = new GraphicsPath()) using (SolidBrush brush = new SolidBrush(ColorBgra.Black)) using (Font font = new Font("Arial", 12)) { g.Clip = gClipRegion; g.SmoothingMode = SmoothingMode.AntiAlias; g.TextRenderingHint = TextRenderingHint.AntiAlias; pen.LineJoin = LineJoin.Round; // add additional GDI+ commands here } normalOp.Apply(dst, src, wrk, rect); } Notice that there are no loops in the Render method. In the Render method, CodeLab generates several "using" blocks. Just delete the ones you won't be using yourself. You'll probably want to modify the remaining "using" statements with user controls to make the various colors and sizes adjustable in your plugin. Finally, you can add additional GDI+ commands to render text, lines, and shapes to the wrk canvas which will then be combined with the source canvas to create your result. Questions and Answers: "Building to DLL now saves to Desktop in a ZIP file." Why would you do that?! Quote Well, now that we have live preview in CodeLab itself, there really isn't as much of a need to "build to dll, install dll, run Paint.NET" to test your plugin. AND, people keep posting zipped DLL files to the forum without including the install.bat file that goes with them. So... I thought it would be convenient to just prepare the zip file for you. This way, it is all ready for you to post to the forum. PLUS, the new install.bat file that is built for you supports both the Classic version and the Store version of Paint.NET. "Matching of Initials in the AutoComplete box filter." What's that?! Quote db - DrawBezier isc - IntSliderControl (and of course IsCancelRequested is still listed, since it starts with isc) 1 4 Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
ReMake Posted September 6, 2018 Share Posted September 6, 2018 CodeLab 4.0 in Russian You can find the new version of CodeLab in Russian here. Вы можете найти новую версию CodeLab на русском языке здесь. Quote Link to comment Share on other sites More sharing options...
xod Posted September 12, 2018 Share Posted September 12, 2018 I think that with the launch of the new version of paint.net 4.1.1 CodeLab should also be revised. Color Wheel Control does not behave properly. As shown in the image below, I chose the Default style but the chosen color has Alpha = 0 although I do not have a slider for Alpha. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted September 12, 2018 Share Posted September 12, 2018 @xod, is the default set to Primary color and is your primary color have alpha set to 0? Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
xod Posted September 12, 2018 Share Posted September 12, 2018 No. And this happens with any plugin. Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted September 12, 2018 Share Posted September 12, 2018 (edited) 2 hours ago, xod said: Color Wheel Control does not behave properly. This is just visual issue in the control itself. The ColorBgra from the control will still have an Alpha channel value 255. The issue is in paint.net v4.1.1; not CodeLab. Edited September 12, 2018 by toe_head2001 Quote (September 25th, 2023) Sorry about any broken images in my posts. I am aware of the issue. My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
xod Posted September 12, 2018 Share Posted September 12, 2018 Yes, you're right is just visual issue. Does not affect the plugins made with OptionBasedLibrary. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted September 13, 2018 Share Posted September 13, 2018 On 9/12/2018 at 8:21 AM, xod said: Color Wheel Control does not behave properly. Thanks for the bug report. It was definitely a bug in Paint.NET. Sorry about that. I submitted a code fix. When Rick approves the fix, it will show up in the next build of Paint.NET. EDIT: It has been approved. 2 1 Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
georch Posted September 16, 2018 Share Posted September 16, 2018 Your server is down, it gives me a HTTP 500 answer from IIS. Can you fix that, or, for that matter, mirror CodeLab elsewhere? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.