Software that makes placemats

Organise events to meet up and drink Port.
Post Reply
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

During the tasting on Tue 11 Oct 2011, five changes to the software were requested.
  • At DRT’s request, HeaderRightText no longer depends on any other parameters, making it easier to move it to the top.
  • Based on a suggestion of PhilW, BackgroundTextsGlassesPaintCode changed from 25% black to 6¼% black.  
  • When RAYC prints, he prints the placenames to card. This is stiff enough to require one fold rather than three, so PlaceNamesFirstAndThirdFoldsFromEdge should be set to zero. I promised to add a feature that checked this parameter’s equality to zero, and if so, not to print the lines and instructions. Except that this was already being checked in just this manner. So, no change to software required. But note to self: if RAYC is to print then set /PlaceNamesFirstAndThirdFoldsFromEdge 0 def.
  • I noticed that the ‘which shipper’ sheet still had the instruction ‟Record points, not rank.” These words have been moved to the parameter VoteRecorderInstruction.
  • RAYC requested a sheet on which corks and cork fragments could be put, both for photography and for observation by others. This has not yet been done, whilst I ponder the range of variations that might be wanted.
And a bonus:
  • All placemats now include a link to this thread.
PhilW
Dalva Golden White Colheita 1952
Posts: 3536
Joined: 14:22 Wed 15 Dec 2010
Location: Near Cambridge, UK

Re: Software that makes placemats

Post by PhilW »

jdaw1 wrote:[*]Based on a suggestion of PhilW, BackgroundTextsGlassesPaintCode changed from 25% black to 6¼% black.
I would also suggest reducing their overall (font) size to 80% of current, and either increasing the line width by 40% or possible solid filling the characters (at 6.25 or 5%)
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

PhilW wrote:increasing the line width by 40%
Increased by a factor of 1.5.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

jdaw1 wrote:
  • RAYC requested a sheet on which corks and cork fragments could be put, both for photography and for observation by others. This has not yet been done, whilst I ponder the range of variations that might be wanted.
I think that parameters needed are as follows:
  • /CorkDisplay true def, saying whether or not to bother.
  • /GlassesClusteredOnCorkDisplay GlassesClusteredOnDecantingNotes def, saying which glasses go there;
  • CorkDisplayMinWidth and CorkDisplayMinHeight, being minimum sizes.
Then the code works out how many can go on each sheet. Each is a rectangle, surrounded by the Circlearrays text, very small, and containing, larger but not very large, the various title-like texts. Sheets would be discretely titled ‟The Corks”.

Does that work?
User avatar
RAYC
Taylor Quinta de Vargellas 1987
Posts: 2060
Joined: 23:50 Tue 04 May 2010
Location: London

Re: Software that makes placemats

Post by RAYC »

jdaw1 wrote:
jdaw1 wrote:
  • RAYC requested a sheet on which corks and cork fragments could be put, both for photography and for observation by others. This has not yet been done, whilst I ponder the range of variations that might be wanted.
I think that parameters needed are as follows:
  • /CorkDisplay true def, saying whether or not to bother.
  • /GlassesClusteredOnCorkDisplay GlassesClusteredOnDecantingNotes def, saying which glasses go there;
  • CorkDisplayMinWidth and CorkDisplayMinHeight, being minimum sizes.
Then the code works out how many can go on each sheet. Each is a rectangle, surrounded by the Circlearrays text, very small, and containing, larger but not very large, the various title-like texts. Sheets would be discretely titled ‟The Corks”.

Does that work?
Sounds great - if it's ready in time, i can try next month for the GC-SW-QH tasting. But i appreciate this is non-essential!
Rob C.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

jdaw1 wrote:
  • RAYC requested a sheet on which corks and cork fragments could be put, both for photography and for observation by others. This has not yet been done, whilst I ponder the range of variations that might be wanted.
Work has started. This work has revealed that the same chunk of code, with very small changes, appears four times in the current version. It is being wrapped into a sub-routine, perhaps to be called CirclearrayInStraightLine, to do the same a little better. This will result in a minor improvement to the tasting-note pages, as well as being used in cork-display pages. Rejoice!
PhilW
Dalva Golden White Colheita 1952
Posts: 3536
Joined: 14:22 Wed 15 Dec 2010
Location: Near Cambridge, UK

Re: Software that makes placemats

Post by PhilW »

The value "/NonDecanterLabelGlassesNumCopies 1 def" appears a few lines below the comment "% Non-Glasses Pages %". Changing this value to zero appears to stop the glasses pages from being printed. Is this as intended, or what is this variable intended to control?

Also, perhaps a trivial detail but - is there a setting to define the width of any exclusion area on the glasses sheets between the outer ring of text as defined by circlearrays and the inner text defined by titles, belowtitles? In a couple of cases experimenting I found that the inner text can (virtually) meet the outer, and therefore by allowing optionally configurable decrease of the effective inner circle size (in which the title/belowtitle are sized and placed) by a small degree (say <=5%, configurable, or a fixed amount e.g. 1mm) might help clarity?
On a PC the specification of NotePad++ looks encouraging user feedback welcomed
I use Notepad++ daily and find it is an excellent context-sensitive-highlighting text editor for use with many languages including postscript (though I hadn't used it for that particular language before today, I use it for several others regularly); highly recommended.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

PhilW wrote:The value "/NonDecanterLabelGlassesNumCopies 1 def" appears a few lines below the comment "% Non-Glasses Pages %". Changing this value to zero appears to stop the glasses pages from being printed. Is this as intended, or what is this variable intended to control?
This might be slightly mis-placed, but does what it seems to do. Why, oh why? Because several page types, including decanter labels and pre-pour and sticky-labels, contain extracts from the glasses pages. If there are no glasses pages, there cannot be sticky labels. But what if!? Then have glasses pages, and show 0 copies of them.
PhilW wrote:Also, perhaps a trivial detail but - is there a setting to define the width of any exclusion area on the glasses sheets between the outer ring of text as defined by circlearrays and the inner text defined by titles, belowtitles? In a couple of cases experimenting I found that the inner text can (virtually) meet the outer, and therefore by allowing optionally configurable decrease of the effective inner circle size (in which the title/belowtitle are sized and placed) by a small degree (say <=5%, configurable, or a fixed amount e.g. 1mm) might help clarity?
They can indeed touch. Such a parameter could be added, though I think it should be expressed a proportion of one of the radii (Radii, RadiiCirclearrayBaseline, or RadiiCirclearrayInside). Suggest a name for the parameter. (Edit: though the boundaries of the Titles etc are separately constrained if there are decanter labels, and of course common sizing will also shrink some.)
PhilW wrote:
On a PC the specification of NotePad++ looks encouraging user feedback welcomed
I use Notepad++ daily and find it is an excellent context-sensitive-highlighting text editor for use with many languages including postscript (though I hadn't used it for that particular language before today, I use it for several others regularly); highly recommended.
Thank you: manual updated.
PhilW
Dalva Golden White Colheita 1952
Posts: 3536
Joined: 14:22 Wed 15 Dec 2010
Location: Near Cambridge, UK

Re: Software that makes placemats

Post by PhilW »

jdaw1 wrote:
PhilW wrote:The value "/NonDecanterLabelGlassesNumCopies 1 def" appears a few lines below the comment "% Non-Glasses Pages %". Changing this value to zero appears to stop the glasses pages from being printed. Is this as intended, or what is this variable intended to control?
This might be slightly mis-placed, but does what it seems to do. Why, oh why? Because several page types, including decanter labels and pre-pour and sticky-labels, contain extracts from the glasses pages. If there are no glasses pages, there cannot be sticky labels. But what if!? Then have glasses pages, and show 0 copies of them.
In that case I wouldn't suggest it was mis-placed, but perhaps a change of name to something like "/InhibitGlassesPagePrinting" for clarity?
jdaw1 wrote:
PhilW wrote:Also, perhaps a trivial detail but - is there a setting to define the width of any exclusion area on the glasses sheets between the outer ring of text as defined by circlearrays and the inner text defined by titles, belowtitles? In a couple of cases experimenting I found that the inner text can (virtually) meet the outer, and therefore by allowing optionally configurable decrease of the effective inner circle size (in which the title/belowtitle are sized and placed) by a small degree (say <=5%, configurable, or a fixed amount e.g. 1mm) might help clarity?
They can indeed touch. Such a parameter could be added, though I think it should be expressed a proportion of one of the radii (Radii, RadiiCirclearrayBaseline, or RadiiCirclearrayInside). Suggest a name for the parameter. (Edit: though the boundaries of the Titles etc are separately constrained if there are decanter labels, and of course common sizing will also shrink some.)
If I've understood the current variables correctly - Radii being the radius to the outside of the circlearray text, and RadiiCircleArrayInside to be the radius to the inside of the circlearray text - then I'd suggest RadiiCirclearrayInsideMargin with default either zero (to print as current) or 0.025 (to provide a 2.5% (radially) gap).
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

PhilW wrote:In that case I wouldn't suggest it was mis-placed, but perhaps a change of name to something like "/InhibitGlassesPagePrinting" for clarity?
Good clarity (though elsewhere I have used !Suppress!); but removes the ≥2 functionality. For what would one want the ≥2 functionality? Hmmm. Not sure. Perhaps for a tasting on a train, in which spillage is expected and substitutions desired? Hmmm.
PhilW wrote:If I've understood the current variables correctly - Radii being the radius to the outside of the circlearray text, and RadiiCircleArrayInside to be the radius to the inside of the circlearray text - then I'd suggest RadiiCirclearrayInsideMargin with default either zero (to print as current) or 0.025 (to provide a 2.5% (radially) gap).
You have understood, though the name might need to be nearer to the rather horrible TitlesEtcInsideMarginProportionRadiiCirclearrayInside.
User avatar
Alex Bridgeman
Graham’s 1948
Posts: 14936
Joined: 13:41 Mon 25 Jun 2007
Location: Berkshire, UK

Re: Software that makes placemats

Post by Alex Bridgeman »

Oh no! More of a thread that might as well be written in Greek for all my understanding.

Perhaps I should reactivate the thread on the technicalities of cricket...
Top Ports in 2023: Taylor 1896 Colheita, b. 2021. A perfect Port.

2024: Niepoort 1900 Colheita, b.1971. A near perfect Port.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

You should delight that, at no effort to yourself, TPF’s finest minds are keeping me in check. Express joy.
User avatar
Alex Bridgeman
Graham’s 1948
Posts: 14936
Joined: 13:41 Mon 25 Jun 2007
Location: Berkshire, UK

Re: Software that makes placemats

Post by Alex Bridgeman »

jdaw1 wrote:You should delight that, at no effort to yourself, TPF’s finest minds are keeping me in check. Express joy.
This is true. I apologise for my earlier, churlish comment. My thanks and appreciation go to those able to contribute meaningfully to this thread and keep Julian challenged and in check.
Top Ports in 2023: Taylor 1896 Colheita, b. 2021. A perfect Port.

2024: Niepoort 1900 Colheita, b.1971. A near perfect Port.
User avatar
Alex Bridgeman
Graham’s 1948
Posts: 14936
Joined: 13:41 Mon 25 Jun 2007
Location: Berkshire, UK

Re: Software that makes placemats

Post by Alex Bridgeman »

AHB wrote:
jdaw1 wrote:You should delight that, at no effort to yourself, TPF’s finest minds are keeping me in check. Express joy.
This is true. I apologise for my earlier, churlish comment. My thanks and appreciation go to those able to contribute meaningfully to this thread and keep Julian challenged and in check.
I raise a glass of port to the good health of you all. Cheers!
Top Ports in 2023: Taylor 1896 Colheita, b. 2021. A perfect Port.

2024: Niepoort 1900 Colheita, b.1971. A near perfect Port.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

In a sheet for displaying corks, what should be the default minimum space required per cork? Three inches across? And how much vertical space? (The algorithm will be efficient about space usage, but the minima are important.)
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

RAYC wrote:if it's ready in time, i can try next month for the GC-SW-QH tasting. But i appreciate this is non-essential!
The manual has not yet been updated, but will be soon.

I hope that people appreciate that this functionality diminished my cellar by a very fine bottle of T77. The sacrifices one makes.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

jdaw1 wrote:The manual has not yet been updated, but will be soon.
Some minor fixes to the new code, and manual updated. Please use the latest code.
User avatar
RAYC
Taylor Quinta de Vargellas 1987
Posts: 2060
Joined: 23:50 Tue 04 May 2010
Location: London

Re: Software that makes placemats

Post by RAYC »

jdaw1 wrote: I hope that people appreciate that this functionality diminished my cellar by a very fine bottle of T77. The sacrifices one makes.
Probably not as much as you appreciated it!
Rob C.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

I have an algorithm problem.

We need a known number of cork-display rectangles, this being computed using CorkDisplayNumCopies and CorkDisplaySpaceForNumExtras. We need to compute how many rows and columns go on each page, subject to CorkDisplayMinWidth and CorkDisplayMinHeight.

So the code loops over /Portrait and /Landscape, computing available space, and loop over numbers of rows and columns:
• Preferring possibilities that meet the CorkDisplayMinWidth and CorkDisplayMinHeight constraints.
• Within those, preferring those requiring as few pages as possible.
• Within those, preferring those for which each rectangle has maximal area.

It’s not bad, but the area preference is wrong, because it has no bias towards rectangles being of the ratio implied by the minima (tall and thin being unhelpful, for example). So, relabelling the minima as H and W, both positive, I want to maximise over positive h and w a function f[h,w,H,W] satisfying:
• f[h,w,H,W] = f[w,h,W,H];
• ∂f[h,w,H,W]/∂h > 0;
• ∂f[h,w,H,W]/∂w > 0;
w/W > h/H ⇔ ∂f[h,w,H,W]/∂h > ∂f[h,w,H,W]/∂w, equality implying equality.
What should be f[!]? I’m stumped. Suggestions please.
User avatar
RAYC
Taylor Quinta de Vargellas 1987
Posts: 2060
Joined: 23:50 Tue 04 May 2010
Location: London

Re: Software that makes placemats

Post by RAYC »

jdaw1 wrote:I have an algorithm problem.

We need a known number of cork-display rectangles, this being computed using CorkDisplayNumCopies and CorkDisplaySpaceForNumExtras. We need to compute how many rows and columns go on each page, subject to CorkDisplayMinWidth and CorkDisplayMinHeight.

So the code loops over /Portrait and /Landscape, computing available space, and loop over numbers of rows and columns:
• Preferring possibilities that meet the CorkDisplayMinWidth and CorkDisplayMinHeight constraints.
• Within those, preferring those requiring as few pages as possible.
• Within those, preferring those for which each rectangle has maximal area.

It’s not bad, but the area preference is wrong, because it has no bias towards rectangles being of the ratio implied by the minima (tall and thin being unhelpful, for example). So, relabelling the minima as H and W, both positive, I want to maximise over positive h and w a function f[h,w,H,W] satisfying:
• f[h,w,H,W] = f[w,h,W,H];
• ∂f[h,w,H,W]/∂h > 0;
• ∂f[h,w,H,W]/∂w > 0;
w/W > h/H ⇔ ∂f[h,w,H,W]/∂h > ∂f[h,w,H,W]/∂w, equality implying equality.
What should be f[!]? I’m stumped. Suggestions please.
I suggest the formation of a working group chaired by AHB :D
Rob C.
PhilW
Dalva Golden White Colheita 1952
Posts: 3536
Joined: 14:22 Wed 15 Dec 2010
Location: Near Cambridge, UK

Re: Software that makes placemats

Post by PhilW »

jdaw1 wrote:What should be f[!]? I’m stumped. Suggestions please.
Perhaps:
f(h,w)=wh/(ah+bw) for all h>=H,w>=W else 0 (invalid)
where a,b are positive constants essentially defining the ideal ratio; a>b, perhaps a=kb where k>1.0, likely ~2.
User avatar
Alex Bridgeman
Graham’s 1948
Posts: 14936
Joined: 13:41 Mon 25 Jun 2007
Location: Berkshire, UK

Re: Software that makes placemats

Post by Alex Bridgeman »

RAYC wrote:I suggest the formation of a working group chaired by AHB :D
I would be delighted to chair such a group, hereby known as the Taylor '77 Working Group.
Top Ports in 2023: Taylor 1896 Colheita, b. 2021. A perfect Port.

2024: Niepoort 1900 Colheita, b.1971. A near perfect Port.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

An opening question for the Taylor 1977 Working Group (‘T77WG’?):
jdaw1 wrote:In a sheet for displaying corks, what should be the default minimum space required per cork? Three inches across? And how much vertical space? (The algorithm will be efficient about space usage, but the minima are important.)
We need the help of somebody who is expert in the handling of broken corks.
User avatar
Alex Bridgeman
Graham’s 1948
Posts: 14936
Joined: 13:41 Mon 25 Jun 2007
Location: Berkshire, UK

Re: Software that makes placemats

Post by Alex Bridgeman »

My suggestion would be to use a minimum length of 3 inches and a minimum width of 2 inches. These dimensions should allow all pieces of a fragmented cork to be reasonably contained in the rectangle.
Top Ports in 2023: Taylor 1896 Colheita, b. 2021. A perfect Port.

2024: Niepoort 1900 Colheita, b.1971. A near perfect Port.
User avatar
jdaw1
Cockburn 1851
Posts: 23719
Joined: 15:03 Thu 21 Jun 2007
Location: London
Contact:

Re: Software that makes placemats

Post by jdaw1 »

So you prefer a portrait display to landscape? I am surprised.
Post Reply