Author Topic: BETA - Image Editor plugin  (Read 85512 times)

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #60 on: August 05, 2010, 10:56:45 pm »
Hello,

SVN is updated (45)

CHANGES:
 1 - ClearSelection called when a click is done
 2 - improved Pen, Brush & Eraser, when mouse is moved fast
 3 - Corrected a bug with the SHIFT key + Select tool.
     Now extend this functionality to all tools

BUGS:
1 - Copy / Paste:
    before copy : bitmap put in clipboard has a Mask
    after paste : bitmap does not have mask
2 - Zoom + Pen does not work good after moving selection
3 - Selection is not drawn when it is overlapping bitmap edges + zoom
4 - Redraw background: the bottom right corner is not covered when zooming out
5 - problem when the selection is bigger than the IMAGEINFO
6 - Drag image: flicker + cursor has a strange position sometimes.
7 - LINUX: Line not displayed dynamically

ROADMAP:
1 - add items 3 to 7 from todo list
2 - solve all the (known) bugs
3 - promote status to Beta
4 - test

Sebastien

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #61 on: August 08, 2010, 03:25:23 pm »
SVN Updated (revision 46)

CHANGES:
 1 - Shift Key extended to other tools.
     Pen, Brush & Eraser to improve in this respect
 2 - Add a ClearSelection that I missed
 3 - LINUX: corrected a nasty bug: crash when using a complex selection
     The crash did not come from ProcessLassoTool as expected, but from IsPointInSelection.
     GTK was trying to create a polygon with less than 3 points => it raised an unhandled exception
     Bug fixed by adding a test
 4 - LINUX: corrected a widespread bug when using the wxMemoryDC.
     wxMemoryDC was created blank (without Bitmap selected). Once created, a wxMemoryDC::IsOk was called.
     On Windows it returns OK when no BMP are selected, but on GTK it returns FALSE
     Hence the drawing never took place, leading to strange results
     Fixed by moving all the call to wxMemoryDC::IsOk after selecting the bitmap

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #62 on: August 09, 2010, 11:34:46 pm »
SVN Updated (47)

CHANGES:
1 - Interpolation improved
2 - Some bugs solved
      a - Selection is not drawn when it is overlapping bitmap edges + zoom
      b - Pen problem after Move Selection + Zoom
      c - Redraw background: the bottom right corner is not covered when zooming out
      d - problem when the selection is bigger than the Image
      e - Drag image: flicker on Win32 + cursor has a strange position sometimes.
3 - Reduced size (width) of the tool palette
4 - added options for Brush & Fill tools
5 - Added stubs & interface for Spray Can tool
    (need to implement 2 methods correctly:
    XPMEditorPanel::ProcessSprayCan() and XPMToolPanel::CreateSprayCanBitmap())
6 - Added stubs & interface for Gradient tool
    (need to implement only XPMEditorPanel::ProcessGradient(). Partially working for Linear gradients, crashing for concentric gradients)


TO DO UNIX:
 1 - add 2 icons (spray can + gradient) to Project
 2 - test that the DragImage is not broken

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: Image Editor - new plugin
« Reply #63 on: August 10, 2010, 08:41:09 am »
SVN Updated (47)

 1 - add 2 icons (spray can + gradient) to Project
...these images are missing in SVN and therefore break compilation. :-)
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #64 on: August 11, 2010, 10:00:09 pm »
SVN Updated (47)

 1 - add 2 icons (spray can + gradient) to Project
...these images are missing in SVN and therefore break compilation. :-)

Just give me the time to reboot and log on Ubuntu. I will fix this immediately.

By the way, SVN updated (rev 49) for Windows (and SVN tested with a check-out on a fresh directory):

CHANGES:
1 - Gradient tool implemented
2 - SprayCan Tool implemented
3 - Text Tool fixed


TO DO UNIX:
 1 - add 2 icons (spray can + gradient) to Project
 2 - test that the DragImage is not broken

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #65 on: August 11, 2010, 11:15:50 pm »
SVN updated (50)

CHANGES & INFO:
1 - added the missing files in LINUX Project
2 - fixed DragImage on LINUX (tested successfully on LINUX and Windows without too much flicker)
3 - spray can & Gradient Linear works on LINUX
4 - Gradient concentric broken on LINUX (wxWidgets bug)

« Last Edit: August 11, 2010, 11:28:16 pm by seb_seb0 »

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #66 on: August 12, 2010, 10:03:49 pm »
SVN updated
I have fixed the wxGTK problem with wxGradientFillConcentric (I have reimplemented it).
A side effect is that it looks nicer on Windows.

I have in parallel submited a a patch to wxWidgets ticket trackers.

I have still a few features to implement (therefore I do not move the status to beta yet). However they are now minor (ctrl-A, copy from / paste to a file)
I consider dropping any kind of customisation options that must be saved in a configuration file: it will make the plugin a bit safer.
I have still a few bugs to solve (see todo.txt)

I would be interested in some feedback from other testers.

Sebastien

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #67 on: August 13, 2010, 09:19:34 pm »
SVN Updated (52)

CHANGES:
1 - some bugs solved (related to right-click handling and font bug).
2 - Select All implemented

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #68 on: August 14, 2010, 11:14:57 pm »
SVN Updated (53)

CHANGES:
1 - bug solved Copy / Paste:
    before copy : bitmap put in clipboard has a Mask
    after paste : bitmap does not have mask
    Solved by adding a custom data format in the clipboard

2 - Change in Text Tool.
    Currently partially broken (orientation not taken into account) due to the changes.

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #69 on: August 17, 2010, 09:19:24 pm »
SVN Updated (54)

CHANGES:
1 - Copy To / Paste from file implemented (via context menu)

2 - DragImage: bug solved to some extent when selection is large (zoomed for example)
    The cursor in that case was disappearing
    In addition, the flicker has been removed
    Solved by reordering the Drawing operations, and modifications of XPMEditorPanel::ProcessDragAction
    (hiding the drag image and repainting were not necessary).
    Note: the bug is still appearing for very big zoom (x16) and large screenshot (screen size)). The system cannot allocate memory I guess (too big bitmap). I am looking for a better way.

3 - Drag action: now holding the shift key will prevent the image to be deleted

4 - Bug solved in Drag Action: 1 or 2 pixels innacuracy in draging selection with the mouse

5 - Bug solved: PasteImage gives a black image when the image is truncated

6 - Bug solved: ClearSelection: when the image to paste is bigger than the destination image, nothing is done sometimes


Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #70 on: August 30, 2010, 10:50:45 pm »
Hello,

I have updated the SVN (revision 55).
I have done many updates in the tool (mainly internal - nearly no new features - I have focused on debugging).

CHANGES:
1 - Copy To / Paste from file implemented (via context menu)

2 - DragImage: bug solved when selection is large (zoomed for example)
    The cursor in that case was disappearing
    In addition, the flicker has been removed
    Solved by reordering the Drawing operations, and modifications of XPMEditorPanel::ProcessDragAction
    (hiding the drag image and repainting were not necessary).

3 - Drag action: now holding the shift key will prevent the image to be deleted

4 - Bug solved in Drag Action: 1 or 2 pixels innacuracy in draging selection with the mouse

5 - Bug solved: PasteImage gives a black image when the image is truncated

6 - Bug solved: ClearSelection: when the image to paste is bigger than the destination image, nothing is done sometimes

7 - Bug solved: MIME Handling: when no extensions was available in the file name, the Plugin was trying to open the file anyway
                and gave no chance to the default MIME handler.

8 - Added default context menu entries in Project Manager

9 - Remove some flickering when creating the editor

10 - Bug solved: When dropping a file on Code::Blocks, the file is displayed correctly - however, the Zoom function does not work.
     Editing & Saving are working.
     Loading the SAME file using the Project Manager or the File/Load menu gives normal results (no bug)

11 - Pen + Brush + Eraser: SHIFT key behaviour implemented

12 - bug solved Copy / Paste:
    before copy : bitmap put in clipboard has a Mask
    after paste : bitmap does not have mask
    Solved by adding a custom data format in the clipboard

13 - Change in Text Tool.
    Currently partially broken (orientation not taken into account) due to the changes.

I am currently working on wxDragImage : I must rewrite it in part, because I have problems with large zoom (up to 1 GB memory used for a stupid bitmap...).

Sebastien

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #71 on: September 02, 2010, 10:34:56 pm »
SVN Updated (revision 56)

I have solved the main bug in wxDragImageExt : the (unreasonnably) large memory consumption leads to the disappearance of the dragged image.
Now this problem is completly solved, removing the last really big bug preventing the plugin from working.

For dragging image, 2 small problems remain:
  1 - there is a flicker when starting the drag (1st click only)
  2 - there is a 1 or 2 pixel innacuracy with big zoom (the image is pasted 1 or 2 pixel too much to the right and to the bottom). Occurs with large zoom factor (I test with zoom = 1600 %)

Sebastien

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #72 on: September 03, 2010, 07:33:19 am »
SVN Updated (revision 57)

CHANGES:
  - licence modified from "GPL" to "GPL v3" in manifest.xml
  - LINUX: Zoom box is now displaying the correct value

BUG FOUND: zoom factor is not working in LINUX anymore. There is probably a problem when scaling the bitmap.  :(

Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #73 on: September 05, 2010, 10:21:05 pm »
SVN Updated (revision 59)

CHANGES:
    1 - fix the bug with wxGTK regarding zooming
    2 - fixing the bug in 1 lead to refactoring wxDragImageExt. This is still a work in progress (changes are not committed in SVN : this is still working in Windows. I seriously doubt it is working on Linux -> I am going to test).

Sebastien


Offline seb_seb0

  • Almost regular
  • **
  • Posts: 166
Re: Image Editor - new plugin
« Reply #74 on: September 23, 2010, 10:14:54 pm »
SVN Updated (revision 60)

Changes:
1 - DragImage partially corrected. There are still 2 bugs
         a - when dragging the selection over the left or top edge of the bitmap, it has an inconsistent behaviour (dragging 1 pixel outside the bitmap will clip the selection by 2 pixels)
         b - when dragging very large bitmap, the selection is clipped too much.

  I am still working on it

2 - scrollbars behaviour improved (scrolled by 1 pixel only)

3 - a few minor bug fixes.

Sebastien