[Gimp-developer] Layer Group boundaries
The implementation of layer groups is progressing very nicely and for the most part they behave as one would expect, and operations upon them behave as I would expect. However, there is one inconsistency that I feel should be considered. Layer groups tend to behave as a sub-image within an image -- operations on the individual layers are limited to the individual layer, whereas operations upon the group layer affect each of the layers in the group (by group layer, I mean the collapsible pseudo-layer educed from the member layers of the group). I.e, cropping, translation, and transformation on the group layer result in each of the layers being cropped or transformed. Similarly, deleting or duplicating the group layer results in the entire group being deleted or duplicated. In these cases, an operation on a group behave just as would the corresponding operation performed upon an image. This is all very intuitive and well implemented. However, to increase the effectiveness of this relationship of group == sub-image, it would be beneficial to have the boundaries of the group behave in a manner analogous to that of the image's canvas size. And currently, it does not. When the boundaries of the group layer are modified, the result is that each of the member layers are cropped to the new boundaries. This is not what I would expect to happen. I should think that the group layer's boundaries should act as a passe-partout, masking out regions of the member layers which happen to lie outside it, and that in manner similar to the behavior of the image canvas, that member layers be permitted to extend beyond the group layer's boundaries. In other words, resizing Layer Boundary Size of the group layer should not crop the layer group, just as changing the canvas size of an image does not crop the image. In addition to the changing the behavior of Layer Boundary Size when a group layer is active, I would propose a new button for the Layers Dialog, one that substitutes for the Lock Alpha button when a group layer is active. This button would permit auto-resizing of the passe-partout to fit the group's member layers. Alternatively, the passe-partout could be initially fixed to the size of the first added member layer, requiring a Fit group canvas to layers or somesuch to modify the size appropriately. Another option would be to create a layermask for the group layer, but this would still require addressing how the positioning and dimensions of the layermask is presented to the user (eventually adding layermasks to group layers would be a desirable enhancement for different reasons). My apologies if there are already plans to address this and I am being premature in presenting this issue, however, I feel it is quite critical that the rendering of the content of layer groups can be restricted to particular regions of the image canvas without requiring that the content of their member layers be destroyed. ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
[Gimp-developer] What are the long-term plans (if any) for OS X?
Hello all- I'm currently working on Seashore, which is a Cocoa app that shares some code with GIMP. The developer that ran the project in the past left so I guess now I'm in charge of the project. I just made my first preview release (you can see it on the webpage http://seashore.sourceforge.net/) However, my understanding is the the original developer of Seashore kind of went off on his own and started this without much involvement of the people actually working on GIMP and that seems like a shame to me. I was wondering if anyone here has long-term plans for supporting the OS X platform. The reason I ask is I don't want to spend any further time on Seashore if there are serious prospects for a native Cocoa GIMP anywhere in the future; I would rather help out with that. If it does not seem like GIMP will ever run natively on OS X, and Seashore is the best we can do in terms of a native Cocoa offering, then I was wondering if anyone here had any tips or advice for working on Seashore (or even if anyone wanted to help out!). Thank you very much, I look forward to hearing from you- Best, Stephen___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
Re: [Gimp-developer] What are the long-term plans (if any) for OS X?
On Wed, Jun 23, 2010 at 6:52 PM, Stephen wrote: I was wondering if anyone here has long-term plans for supporting the OS X platform. The reason I ask is I don't want to spend any further time on Seashore if there are serious prospects for a native Cocoa GIMP anywhere in the future; I would rather help out with that. Stephen, My impression is that everyone is still hoping to see stable builds of GIMP on Mac with Quartz port of GTK+. But somehow it just doesn't happen. Rewriting GIMP in Cocoa by the core GIMP team is out of question: there are too few developers active and none of them using Mac to the best of my knowledge. Alexandre Prokoudine http://libregraphicsworld.org ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
Re: [Gimp-developer] What are the long-term plans (if any) for OS X?
The GIMP can actually already run natively on OS X, at least in theory. There is a build of Gtk+ which uses native Cocoa backend. http://gtk-osx.sourceforge.net/ I've read several posts from people claiming they have built GIMP via jhbuild. There is also the possibility to install the gtk+ from macports with +no_x11+quartz+macos flags and then compile GIMP, however in my case this resulted in a bogus pango. Currently I'm trying to make an application bundle of Gimp using Gtk+ for Cocoa, but I haven't had much time lately. ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
Re: [Gimp-developer] What are the long-term plans (if any) for OS X?
On 06/23/2010 04:52 PM, Stephen wrote: Hello all- [...] I was wondering if anyone here has long-term plans for supporting the OS X platform. The reason I ask is I don't want to spend any further time on Seashore if there are serious prospects for a native Cocoa GIMP anywhere in the future; I would rather help out with that. Hi Stepehen The GIMP project has for a long time wanted help from someone with OS X experience, we absolutely want GIMP to work good and build for Mac OS X. I think a good first step would be to port Seashore Mac OS adaptations to upstream GIMP. Thanks a lot in advance for any help you will give us to make GIMP play more nicely with Mac OS X. Best regards, Martin -- My GIMP Blog: http://www.chromecode.com/ Automatic tab style and removed tab title bar ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
[Gimp-developer] Creating unique file names with Script-Fu
Hi. I'm working on a script in which I would like to insert a sequence of commands aimed to save a drawable as PAT file and eventually, when no longer needed, eliminate the file in question. This trick allows to create a temporary pattern existing only during the script execution, so as to fill a layer or a channel with the content of the drawable this pattern derives from. The problem is that I can’t choose whatever arbitrary name for the PAT file, because the destination folder might contain a file with the same name, which would therefore run the risk of being overwritten and lastly removed by the script. So, this observation points out the necessity of implementing a method for creating unique file names by means of the Scipt-Fu language. Personally, instead of writing conditional statements which cyclically verify the existence of a certain file name (with the “file-exists?” procedure), I have thought about the possibility of using the “dir-read-entry” procedure. Supposing to store the result of this command into a variable named F1, if F1 equals #EOF, the target directory is empty, thus any name can be chosen (for instance, “0.pat”). If the folder is not empty instead, F1 will return the name of the alphabetically first element (file or folder) inside such directory. In this case, a solution may be to create a new string called F2 by connecting the character “!”, the string F1 and, finally, the string “.pat”. Having noticed that the exclamation point is the first available symbol for naming files/folders (at least, on Windows platform), well the string F2 shall precede the string F1 in alphabetical order, so as to furnish, this way, a valid and unique file name which doesn't already exist within the folder, as confirmed by the fact that further invocations of “dir-read-entry” will return strings of higher order. In short, here is the set of procedures I imagine: (define PD (string-append gimp-data-directory \\patterns\\)) (define STM (dir-open-stream PD)) (define F1 (dir-read-entry STM)) (if (eof-object? F1) (define F2 (string-append PD 0.pat)) (define F2 (string-append PD ! F1 .pat)) ) (file-pat-save 1 IMG DRW1 F2 “” “My Pattern”) (dir-close-stream STM) (gimp-patterns-refresh) (gimp-context-set-pattern “My Pattern”) (gimp-edit-bucket-fill DRW2 2 0 100 255 1 0 0) (file-delete F2) (gimp-patterns-refresh) After doing several tests, my impression is that such a stratagem should work well. Nevertheless, I'm not totally sure of its infallibility, because, among other things, I don't know if the character “!” is really the first valid symbol on all operating systems supported by GIMP, as well as I can't figure out if there are any character combinations that invalidate my remarks on the alphabetical priority performed by appending the exclamation point before whatever string. Can anyone clarify my doubts and definitely confirm or deny the effectiveness of the method I have just stated? Moreover, any suggestions on how to generate unique file names in a different and simpler way? Thanks in advance. ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
Re: [Gimp-developer] Creating unique file names with Script-Fu
Quoting Gino D ginodo...@gmail.com: I'm working on a script in which I would like to insert a sequence of commands aimed to save a drawable as PAT file and eventually, when no longer needed, eliminate the file in question. I do not believe it is possible for a Script-fu to delete files. You will need to either do this outside of GIMP or write a plug-in. The problem is that I can’t choose whatever arbitrary name for the PAT file, because the destination folder might contain a file with the same name, which would therefore run the risk of being overwritten and lastly removed by the script. So, this observation points out the necessity of implementing a method for creating unique file names by means of the Scipt-Fu language. : : Can anyone clarify my doubts and definitely confirm or deny the effectiveness of the method I have just stated? Moreover, any suggestions on how to generate unique file names in a different and simpler way? I don't have time right now to review your approach, however, ... The following code snippet uses 'gimp-temp-name' -- which generates a filename that has an extremely good chance of being unique -- however, just to be certain, an attempt is made to open the file (in your directory, not the ~/.gimp/tmp directory). If the open succeeds, the file is closed and the process repeated. (let ((basename ) (filename ) (port #t)) (while port (set! basename (car (last (strbreakup (car (gimp-temp-name pat)) / (set! filename (string-append /path/to/directory/ basename)) (set! port (open-input-file filename)) (when port (close-output-port port) ) ) ; filename is unique of the form /path/to/directory/gimp-temp-##.pat For better cross-platform support, you should replace the slashes above with the DIR-SEPARATOR system constant. ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer
[Gimp-developer] possible to announce here an upcoming update ?
Is it possible to announce with a few days before an upcoming update release ? I have missed a translation update for 2.6.9 because I didn't know it would happen. Thank you, Cristi -- Cristian Secară http://www.secarica.ro ___ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer