issue182:inkscape
Différences
Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
issue182:inkscape [2022/06/27 09:25] – créée auntiee | issue182:inkscape [2022/07/01 15:50] (Version actuelle) – andre_domenech | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | Right on schedule, Inkscape 1.2 was released last month with a lot of new features, and updates to the existing UI. I will be covering everything in detail in this column, but not just yet. In the meantime, if you want a good overview of the headline features, I strongly recommend taking two minutes out of your day to watch the very professionally produced official release video: https:// | + | **Right on schedule, Inkscape 1.2 was released last month with a lot of new features, and updates to the existing UI. I will be covering everything in detail in this column, but not just yet. In the meantime, if you want a good overview of the headline features, I strongly recommend taking two minutes out of your day to watch the very professionally produced official release video: https:// |
- | For now, these articles are still working through the many new Live Path Effects (LPEs) that were added with Inkscape 1.0 and 1.1. The topic for this instalment is a pair of new LPEs – “Power Clip” and “Power Mask” – which I first mentioned back in part 101. That article detailed the use of the new “Inverse Clip” and “Inverse Mask” menu entries, with little more than a scant reference to the fact that they’re actually implemented as LPEs. Now it’s time to dig into the effects that back these capabilities in a little more detail. | + | For now, these articles are still working through the many new Live Path Effects (LPEs) that were added with Inkscape 1.0 and 1.1. The topic for this instalment is a pair of new LPEs – “Power Clip” and “Power Mask” – which I first mentioned back in part 101. That article detailed the use of the new “Inverse Clip” and “Inverse Mask” menu entries, with little more than a scant reference to the fact that they’re actually implemented as LPEs. Now it’s time to dig into the effects that back these capabilities in a little more detail.** |
- | Power Clip | + | Comme prévu, Inkscape 1.2 est sorti le mois dernier avec de nombreuses nouvelles fonctionnalités et des mises à jour de l' |
+ | |||
+ | Pour l' | ||
+ | |||
+ | |||
+ | **Power Clip | ||
I won’t sugar coat this: I think the name of this LPE is making a very bold claim that is far from matched by reality. As far as I can tell, this effect usefully does one and only one thing, and doesn’t really deserve the “Power” prefix at all. The only practical use for this LPE is to create inverse clipping paths. | I won’t sugar coat this: I think the name of this LPE is making a very bold claim that is far from matched by reality. As far as I can tell, this effect usefully does one and only one thing, and doesn’t really deserve the “Power” prefix at all. The only practical use for this LPE is to create inverse clipping paths. | ||
Ligne 9: | Ligne 14: | ||
Adding this effect to a path works a little differently to almost every other LPE. You can’t simply select a path and add the Power Clip effect from the usual dialog. If you try, you’ll just find that the option is disabled (as is Power Mask, for similar reasons). | Adding this effect to a path works a little differently to almost every other LPE. You can’t simply select a path and add the Power Clip effect from the usual dialog. If you try, you’ll just find that the option is disabled (as is Power Mask, for similar reasons). | ||
- | A clipping path requires one other element to act on – the thing you’re trying to clip. That single element could, of course, be a group consisting of several other items, which allows complex designs to be easily clipped. But the clipping path itself is applied to only one element or group. | + | A clipping path requires one other element to act on – the thing you’re trying to clip. That single element could, of course, be a group consisting of several other items, which allows complex designs to be easily clipped. But the clipping path itself is applied to only one element or group.** |
- | With this in mind, you might think that this LPE will become available if you have two items selected. In practice, however, the Path Effects dialog itself will chastise you with an “Only one item can be selected” message, and the “+” button will be disabled to prevent you even opening the Live Path Effects Selector dialog. How, then, do we apply this LPE in the first place? | + | Découpe avancée |
+ | |||
+ | Je ne vais pas mettre des gants blancs pour le dire : je pense que le nom de ce LPE est une affirmation très audacieuse qui est loin de correspondre à la réalité. Pour autant que je sache, cet effet ne fait qu'une seule et unique chose, et ne mérite pas vraiment l' | ||
+ | |||
+ | L' | ||
+ | |||
+ | Un chemin de découpe nécessite un autre élément sur lequel agir : l' | ||
+ | |||
+ | |||
+ | **With this in mind, you might think that this LPE will become available if you have two items selected. In practice, however, the Path Effects dialog itself will chastise you with an “Only one item can be selected” message, and the “+” button will be disabled to prevent you even opening the Live Path Effects Selector dialog. How, then, do we apply this LPE in the first place? | ||
There are actually two methods: | There are actually two methods: | ||
Ligne 17: | Ligne 31: | ||
• The other is to apply a normal clip, either via the context menu or using the Object > Clip > Set menu entry, then use the Path Effects dialog to add the LPE as usual. | • The other is to apply a normal clip, either via the context menu or using the Object > Clip > Set menu entry, then use the Path Effects dialog to add the LPE as usual. | ||
- | Yes, if you have an already clipped object selected, only then will you be able to add this LPE in the normal manner. | + | Yes, if you have an already clipped object selected, only then will you be able to add this LPE in the normal manner.** |
- | Whichever approach you take, this LPE really, really wants to create an inverted clip. If you add it directly via the menu entry, then that’s what will happen, as you would expect. Adding it via the dialog to an already clipped object, however, will immediately invert the clip that you’ve already applied – which might be a little more surprising if you’re not expecting it. | + | En gardant cela à l' |
+ | |||
+ | Il existe en fait deux méthodes : | ||
+ | ••La première consiste à l' | ||
+ | ••L' | ||
+ | |||
+ | Oui, si vous avez sélectionné un objet déjà découpé, ce n'est que dans ce cas que vous pourrez ajouter ce LPE de la manière habituelle. | ||
+ | |||
+ | |||
+ | **Whichever approach you take, this LPE really, really wants to create an inverted clip. If you add it directly via the menu entry, then that’s what will happen, as you would expect. Adding it via the dialog to an already clipped object, however, will immediately invert the clip that you’ve already applied – which might be a little more surprising if you’re not expecting it. | ||
As a reminder, a normal clip preserves everything inside the path, and hides the content outside. An inverse clip, therefore, hides everything inside the path but preserves anything outside, per the image below. | As a reminder, a normal clip preserves everything inside the path, and hides the content outside. An inverse clip, therefore, hides everything inside the path but preserves anything outside, per the image below. | ||
If you really want a normal clip, then you can uncheck the “Inverse clip” option in the LPE’s parameters – though doing so raises the obvious question of why you want to use the LPE at all in that case. | If you really want a normal clip, then you can uncheck the “Inverse clip” option in the LPE’s parameters – though doing so raises the obvious question of why you want to use the LPE at all in that case. | ||
- | Perhaps the “power” in this LPE actually comes from the other two parameters? Well, the “Hide clip” option simply modifies the clipping path to remove the nodes that actually do the clipping – again, raising a question about why you wouldn’t just remove the clip entirely. As for “Flatten clip”: this is another entry in my box of LPE mystery parameters that appear to do something, but it’s not entirely clear quite what that something is. My own experiments with various combinations of objects and groups, primitives and paths, have failed to present me with any situation in which it does something useful. As usual, if you have any idea of how it’s meant to be used, please do get in touch. | + | Perhaps the “power” in this LPE actually comes from the other two parameters? Well, the “Hide clip” option simply modifies the clipping path to remove the nodes that actually do the clipping – again, raising a question about why you wouldn’t just remove the clip entirely. As for “Flatten clip”: this is another entry in my box of LPE mystery parameters that appear to do something, but it’s not entirely clear quite what that something is. My own experiments with various combinations of objects and groups, primitives and paths, have failed to present me with any situation in which it does something useful. As usual, if you have any idea of how it’s meant to be used, please do get in touch.** |
- | One final important note about this LPE is how to go about removing it. If you only want to temporarily stop it being applied, then the usual approach with an LPE is to toggle the visibility icon (the “eye” image) in the Path Effects dialog. This may not, however, work as you expect. It will remove the inverting effect of the LPE, but still leave your object with the non-inverted clip applied. If you really want to see the object with no clip at all, then you’re back to using the “Hide” option in the LPE’s parameters. This feels a little awkward to me, as it requires users to understand too much about the implementation of clipping masks in SVG to fully appreciate why the normal visibility toggle doesn’t work the way they might expect. | + | Quelle que soit l' |
- | Permanently removing this effect is even worse. Should you be foolish enough to delete the effect from the Path Effects dialog, as you might usually do, then you’re likely to find that your clipped objects disappear as well – almost certainly not what you wanted! Instead you have to release the clip using the Object > Clip > Release menu entry, or the context menu alternative. Even that comes with a sting in the tail: your original clipping path will also be deleted, so if you wanted to retain both that path and the object being clipped, you’re out of luck. | + | Pour rappel, une découpe normale préserve tout ce qui se trouve à l' |
- | With that exhaustive examination of this “power” LPE, I’ve come to the conclusion that it serves only one useful purpose: to simplify the task of punching a hole in another object using a clipping path. To be fair, I think this is an exceptionally useful ability. I’m just not sure it warrants the “power” prefix, rather than simply being called “Inverse clip”. As useful as it is, do be aware of the problems and limitations that come with it. If you’ve got enough experience with Inkscape to be able to make your own inverse | + | Si vous voulez vraiment une découpe normale, vous pouvez décocher l' |
- | Power Mask | + | Peut-être que l'« avance » de ce LPE provient en fait des deux autres paramètres ? L' |
+ | |||
+ | |||
+ | **One final important note about this LPE is how to go about removing it. If you only want to temporarily stop it being applied, then the usual approach with an LPE is to toggle the visibility icon (the “eye” image) in the Path Effects dialog. This may not, however, work as you expect. It will remove the inverting effect of the LPE, but still leave your object with the non-inverted clip applied. If you really want to see the object with no clip at all, then you’re back to using the “Hide” option in the LPE’s parameters. This feels a little awkward to me, as it requires users to understand too much about the implementation of clipping masks in SVG to fully appreciate why the normal visibility toggle doesn’t work the way they might expect. | ||
+ | |||
+ | Permanently removing this effect is even worse. Should you be foolish enough to delete the effect from the Path Effects dialog, as you might usually do, then you’re likely to find that your clipped objects disappear as well – almost certainly not what you wanted! Instead you have to release the clip using the Object > Clip > Release menu entry, or the context menu alternative. Even that comes with a sting in the tail: your original clipping path will also be deleted, so if you wanted to retain both that path and the object being clipped, you’re out of luck.** | ||
+ | |||
+ | Une dernière remarque importante à propos de ce LPE concerne la manière de le supprimer. Si vous voulez seulement empêcher temporairement son application, | ||
+ | |||
+ | Supprimer définitivement cet effet est encore pire. Si vous êtes assez fou pour supprimer l' | ||
+ | |||
+ | |||
+ | **With that exhaustive examination of this “power” LPE, I’ve come to the conclusion that it serves only one useful purpose: to simplify the task of punching a hole in another object using a clipping path. To be fair, I think this is an exceptionally useful ability. I’m just not sure it warrants the “power” prefix, rather than simply being called “Inverse clip”. As useful as it is, do be aware of the problems and limitations that come with it. If you’ve got enough experience with Inkscape to be able to make your own inverse clipping paths, as I described way back in part 13, perhaps sticking with the old-fashioned approach is still the safer option.** | ||
+ | |||
+ | Après l' | ||
+ | |||
+ | |||
+ | **Power Mask | ||
Masks are often thought of as a more “analogue” version of clipping. Whereas clips provide hard edges and a binary visible/ | Masks are often thought of as a more “analogue” version of clipping. Whereas clips provide hard edges and a binary visible/ | ||
- | I prefer to keep my masks in shades of gray to provide clear control over their effects. A typical mask would use white for those areas that are to remain 100% opaque, black for those that are to become completely transparent, | + | I prefer to keep my masks in shades of gray to provide clear control over their effects. A typical mask would use white for those areas that are to remain 100% opaque, black for those that are to become completely transparent, |
- | When applied as a normal mask, the white center to the design should ensure that the middle of the star remains solid, while the gradient out to the black edge will fade out the points of the star long before we reach their ends. Selecting both the star and the mask, then using the “Set Mask” context menu entry (or Object > Mask > Set) does, indeed, give the result we would expect (shown against a chequerboard background so you can see which parts are translucent). | + | Masque avancé |
+ | |||
+ | Les masques sont souvent considérés comme une version plus « réaliste » du découpage. Alors que les clips fournissent des bords durs et un état binaire visible/ | ||
+ | |||
+ | Je préfère garder mes masques en nuances de gris pour permettre un contrôle clair de leurs effets. Un masque typique utilise le blanc pour les zones qui doivent rester 100% opaques, le noir pour celles qui doivent devenir complètement transparentes, | ||
+ | |||
+ | |||
+ | **When applied as a normal mask, the white center to the design should ensure that the middle of the star remains solid, while the gradient out to the black edge will fade out the points of the star long before we reach their ends. Selecting both the star and the mask, then using the “Set Mask” context menu entry (or Object > Mask > Set) does, indeed, give the result we would expect (shown against a chequerboard background so you can see which parts are translucent). | ||
What would you expect the result to be if, instead, we use Object > Mask > Set Inverse (LPE)? Based on the behaviour of the Power Clip effect, you might imagine that the middle will be punched out of the star, leaving the points in place but fading towards a large central hole. That’s certainly what I expected the first time I used this effect, but the actual outcome is somewhat different. | What would you expect the result to be if, instead, we use Object > Mask > Set Inverse (LPE)? Based on the behaviour of the Power Clip effect, you might imagine that the middle will be punched out of the star, leaving the points in place but fading towards a large central hole. That’s certainly what I expected the first time I used this effect, but the actual outcome is somewhat different. | ||
- | Let’s take a closer look at the LPE’s parameters to work out exactly what’s happening here. | + | Let’s take a closer look at the LPE’s parameters to work out exactly what’s happening here.** |
- | Interestingly, | + | Lorsqu' |
+ | |||
+ | Quel serait le résultat attendu si, à la place, nous utilisions Objet > Masque > Inverser (LPE) ? En se basant sur le comportement de l' | ||
+ | |||
+ | Regardons de plus près les paramètres du LPE pour comprendre exactement ce qui se passe ici. | ||
+ | |||
+ | |||
+ | **Interestingly, | ||
With that in mind, the end result is a little more understandable. But it’s not exactly what I would expect from a menu entry that bills itself as an “inverse mask”. Perhaps if we enable the “Invert mask” option, we’ll get something closer to our expectations… | With that in mind, the end result is a little more understandable. But it’s not exactly what I would expect from a menu entry that bills itself as an “inverse mask”. Perhaps if we enable the “Invert mask” option, we’ll get something closer to our expectations… | ||
- | Hmm… not really. The problem now is that we’ve inverted every part of our mask – swapping black for white, light gray for dark gray, and so on – but that also includes the color of the background we’ve added. Now, therefore, the mask looks like this: | + | Hmm… not really. The problem now is that we’ve inverted every part of our mask – swapping black for white, light gray for dark gray, and so on – but that also includes the color of the background we’ve added. Now, therefore, the mask looks like this:** |
+ | |||
+ | Il est intéressant de noter que, bien qu' | ||
+ | |||
+ | Avec cela en tête, le résultat final est un peu plus compréhensible. Mais ce n'est pas exactement ce que j' | ||
+ | |||
+ | Hmm... pas vraiment. Le problème, c'est que nous avons inversé chaque partie de notre masque, en remplaçant le noir par le blanc, le gris clair par le gris foncé, etc. Maintenant, le masque ressemble donc à ceci : | ||
- | Again this explains the output we’re seeing, but it’s still not really what we had expected from an inverse mask. What we need is the hole in the middle from this version, but with the points of the stars still being visible, as we had in the previous one. In other words, we want a black center fading to a white shape that continues to fill the whole bounding box. The way to achieve that is to change the background color to black, so that the “Invert mask” checkbox has the effect of converting it to white. With that change, we finally get the look I was expecting from the outset. | + | **Again this explains the output we’re seeing, but it’s still not really what we had expected from an inverse mask. What we need is the hole in the middle from this version, but with the points of the stars still being visible, as we had in the previous one. In other words, we want a black center fading to a white shape that continues to fill the whole bounding box. The way to achieve that is to change the background color to black, so that the “Invert mask” checkbox has the effect of converting it to white. With that change, we finally get the look I was expecting from the outset. |
To summarise, in order to create what I would consider to be the inverse of my mask, I had to do the following: | To summarise, in order to create what I would consider to be the inverse of my mask, I had to do the following: | ||
Ligne 58: | Ligne 119: | ||
• Set the “Invert mask” option | • Set the “Invert mask” option | ||
• Ensure the “Add background” option is checked | • Ensure the “Add background” option is checked | ||
- | • Set the background color to black | + | • Set the background color to black** |
- | That really is a lot of work, and it’s clear that the “Set Inverse (LPE)” option didn’t really do much to help us out. My advice, therefore, is to skip this LPE entirely, and just construct the mask you need with the right colors from the outset. Here’s what I would actually do to achieve the same result: | + | Encore une fois, cela explique le résultat que nous voyons, mais ce n'est toujours pas ce que nous attendions d'un masque inverse. Ce dont nous avons besoin est le trou au milieu de cette version, mais avec les pointes de l' |
+ | |||
+ | Pour résumer, afin de créer ce que je considère comme l' | ||
+ | ••Dessiner le masque. | ||
+ | ••L' | ||
+ | ••Ouvrir la boîte de dialogue Effets de Chemin Interactifs pour accéder aux paramètres. | ||
+ | ••Définir l' | ||
+ | ••Vous assurer que l' | ||
+ | ••Définir la couleur de l' | ||
+ | |||
+ | |||
+ | **That really is a lot of work, and it’s clear that the “Set Inverse (LPE)” option didn’t really do much to help us out. My advice, therefore, is to skip this LPE entirely, and just construct the mask you need with the right colors from the outset. Here’s what I would actually do to achieve the same result: | ||
• Draw a white rectangle that covers the star | • Draw a white rectangle that covers the star | ||
• Draw a black circle in the middle | • Draw a black circle in the middle | ||
Ligne 67: | Ligne 139: | ||
• Select both the mask and the star, then use Object > Mask > Set | • Select both the mask and the star, then use Object > Mask > Set | ||
- | Admittedly it’s barely any fewer steps, but I’ll wager that this approach is a lot more intuitive to anyone with even a little experience using Inkscape. | + | Admittedly it’s barely any fewer steps, but I’ll wager that this approach is a lot more intuitive to anyone with even a little experience using Inkscape.** |
+ | |||
+ | C'est vraiment beaucoup de travail, et il est clair que l' | ||
+ | ••Dessiner un rectangle blanc qui couvre l' | ||
+ | ••Dessiner un cercle noir au milieu. | ||
+ | ••Flouter le cercle, ou lui donner un dégradé de noir à blanc pour créer des bords doux. | ||
+ | ••Regrouper le cercle et le rectangle pour créer le masque final. | ||
+ | ••Sélectionner à la fois le masque et l' | ||
+ | |||
+ | Certes, il n'y a guère moins d' | ||
+ | |||
+ | |||
+ | **And there you have these two new “power” LPEs which, on the surface, promise so much, yet deliver so little in reality. The Power Clip is potentially useful, but may create problems when you want to release the clip later. The Power Mask just doesn’t do anything that you can’t achieve by hand almost as easily, if not moreso. They’re both useful tools to know about, though – if only so that you understand how to achieve the same results without having to get the LPEs involved at all!** | ||
+ | |||
+ | Et voilà ces deux nouveaux LPE « avancés » qui, en surface, promettent tant de choses, mais en réalité en offrent si peu. La Découpe avancée est potentiellement utile, mais peut créer des problèmes lorsque vous voulez libérer le découpage plus tard. Le Masque avancé ne fait rien que vous ne puissiez réaliser à la main presque aussi facilement, sinon plus. Ces deux outils sont néanmoins utiles à connaître, ne serait-ce que pour comprendre comment obtenir les mêmes résultats sans avoir à faire appel aux LPE ! | ||
- | And there you have these two new “power” LPEs which, on the surface, promise so much, yet deliver so little in reality. The Power Clip is potentially useful, but may create problems when you want to release the clip later. The Power Mask just doesn’t do anything that you can’t achieve by hand almost as easily, if not moreso. They’re both useful tools to know about, though – if only so that you understand how to achieve the same results without having to get the LPEs involved at all! | ||
issue182/inkscape.1656314718.txt.gz · Dernière modification : 2022/06/27 09:25 de auntiee