Jump to content
You must now use your email address to sign in [click for more info] ×

Recommended Posts

Are there other variables to use besides "Slice Name" when setting up file naming in an export preset? I'm exporting several artboards to PDF and would like my FileName_ to be appended to the beginning of each PDF (not just the SliceName). The two workarounds I've found are:

  1. Name each artboard with the filename at the beginning of it (but this is messy and doesn't allow you to see the artboard's name unless my Layers panel is really wide).
  2. Manually enter the FileName_ text in front of the SliceName variable in the Export setup, but obviously this is time consuming and prone to errors.

Thanks in advance!

Link to comment
Share on other sites

Welcome to the Serif Affinity forums, @philliphandsome.

If you click in the filename part of the Slices panel you'll get a dialog box where you can define variables and their values:

image.png.0aabfabbc55be7725cf882b373d76d12.png

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
iPad:  iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1

Link to comment
Share on other sites

18 hours ago, walt.farrell said:

If you click in the filename part of the Slices panel you'll get a dialog box where you can define variables and their values:

At least in the Mac versions of AD & AP, (from what I can tell) very annoyingly these so-called "variables" only can be applied to the current slice, so to use them in multiple slices they have to be defined separately for each slice!

This makes them just about useless for this. In fact, all they do is add extra steps to naming slices vs. just typing in the text in the Path components box directly.

So am I missing something or is it the same for everybody?

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

6 hours ago, R C-R said:

At least in the Mac versions of AD & AP, (from what I can tell) very annoyingly these so-called "variables" only can be applied to the current slice, so to use them in multiple slices they have to be defined separately for each slice!

This makes them just about useless for this. In fact, all they do is add extra steps to naming slices vs. just typing in the text in the Path components box directly.

So am I missing something or is it the same for everybody?

I had never noticed that, R C-R, but I can confirm it works the same way on Windows.

That feels like it should be a bug, but as the documentation is sparse it's hard to be sure. Still, as you say, the user variables are pretty useless with the current implementation. Unless there's something we're both missing.

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
iPad:  iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1

Link to comment
Share on other sites

Thanks, @Lagarto. That is one good thing about them, that I had not realized.

But suppose youre going to export 3 slices in a project, and each needs the same variable. You need to specify that variable individually for each slice. That's what seems odd.

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
iPad:  iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1

Link to comment
Share on other sites

Thanks, @Lagarto.

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
iPad:  iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1

Link to comment
Share on other sites

59 minutes ago, walt.farrell said:

But suppose youre going to export 3 slices in a project, and each needs the same variable. You need to specify that variable individually for each slice. That's what seems odd.

What seems most odd to me is that the values of these variables are not actually variables in any traditional sense I am aware of. IOW, if one is set to "AFFDEBUG" that is what it always will be, no matter where its name is used as a substitute for that literal text string.

I had hoped a value could be set to something like the product of the width times the height of the slice but it is always interpreted as a text string.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

1 hour ago, Lagarto said:

So they vary meaningfully, and I could not ask more.

I could ask for more for the custom variables:

  1. That they were 'document-global' -- IOW, that a named variable was usable with any export of that document.
  2. That they were true variables in the usual programatic sense, so that for example they accepted expressions (so string literals appearing in them would need to be enclosed in quotes) & accepted other variables, including the factory ones.

This would allow things like exported document names including megapixels or concatenating several factory variables & optionally text separators into a single variable, so that it could be used in place of the several ones like in your screenshot.

At least on Macs, this would be useful with the built-in ability to batch change file names or with Applescripts or Automator after the export to sort, rename, or do other things with the exported files, based on their filenames.

Maybe in version 2 we will see something like that....

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

3 hours ago, Lagarto said:

Technically these are parameters to a filename so they need to be simple and receive expected data.

I am not sure what you mean by simple but long & reasonably complex file pathnames are well supported, at least in the Mac OS, & are already sometimes used for sorting or other automated tasks, so it would be useful to support them in custom variables to simplify certain kinds of post export processing.

However, I do agree that other things are currently more important, thus my 'maybe version 2' comment.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

  • 1 year later...
On 4/9/2020 at 7:41 PM, walt.farrell said:

But suppose youre going to export 3 slices in a project, and each needs the same variable. You need to specify that variable individually for each slice. That's what seems odd.

Seams to be the same now. I find it weird and not purpose how is implemented.

User variables editor should be global on a separated window as Studio -> User variables.
Name, Value, Description
 

And on the User variables should be listed all variables like how theimage.png.231093c8556dc8939763c8569b07bb97.png are listed.

Like: image.png.d453758fad103699f29ed00568c89ea5.png

I rather type the text on the Path components and copy to all rather wasting time to add a variable.

Link to comment
Share on other sites

  • 1 year later...

Now stumbling on this useless feature of slice variable names. For my case I want a template where I define a set of standard sized slices for views Top, Left, Front etc and then set a single variable so that the images are named after the variable plus the slice name so if the Variable is Jeep the images will be JeepTop JeepLeft etc. Alas the user variables are not global to the file or export persona but local to the slice and so it's much quicker to just name the slices directly rather than setting a variable once. This means having a variable to name slices is wholly a redundant feature that has to be maintained and tested. Is there a Forum to raise such dunsel features with serif it should be named appropriately.

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.
Note: Your post will require moderator approval before it will be visible.

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.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.