The scrlttr2 signature position with KOMA-Script pseudolength sigindent?What is the use of percent signs (%) at the end of lines?Signatures side by sideHow to position the reference fields line in scrlttr2scrlttr2 no firstheadscrlttr2: Position of the recipient's addressUsing mailmerge with scrlttr2 KOMA letter classKomascript scrlttr2: how to change name in signature?Including a signature image in scrlttr2Including signature images kills scrlttr2scrlttr2 positioning - signature business title and name in same linescrlttr2 position of logo relative to addressSetting the date position to the top right in a NF.lco (french style) koma scrlttr2

I see my dog run

Could Giant Ground Sloths have been a good pack animal for the ancient Mayans?

What does "enim et" mean?

Why doesn't a const reference extend the life of a temporary object passed via a function?

Where to refill my bottle in India?

extract characters between two commas?

What is it called when one voice type sings a 'solo'?

How can I add custom success page

How to move the player while also allowing forces to affect it

Is every set a filtered colimit of finite sets?

How to make payment on the internet without leaving a money trail?

Why airport relocation isn't done gradually?

Does it makes sense to buy a new cycle to learn riding?

What is GPS' 19 year rollover and does it present a cybersecurity issue?

Does the average primeness of natural numbers tend to zero?

Is there any use for defining additional entity types in a SOQL FROM clause?

Crop image to path created in TikZ?

What does 'script /dev/null' do?

Typesetting a double Over Dot on top of a symbol

Denied boarding due to overcrowding, Sparpreis ticket. What are my rights?

Is there a way to make member function NOT callable from constructor?

Extreme, but not acceptable situation and I can't start the work tomorrow morning

Filling an area between two curves

Creating a loop after a break using Markov Chain in Tikz



The scrlttr2 signature position with KOMA-Script pseudolength sigindent?


What is the use of percent signs (%) at the end of lines?Signatures side by sideHow to position the reference fields line in scrlttr2scrlttr2 no firstheadscrlttr2: Position of the recipient's addressUsing mailmerge with scrlttr2 KOMA letter classKomascript scrlttr2: how to change name in signature?Including a signature image in scrlttr2Including signature images kills scrlttr2scrlttr2 positioning - signature business title and name in same linescrlttr2 position of logo relative to addressSetting the date position to the top right in a NF.lco (french style) koma scrlttr2













2















I'm trying to align the signature with the destination address in a french styled letter.

I could use the very good lettre class as mentioned in my previous question but I need to scrlttr2 to reuse the org-mode koma export back-end.



I tried setting the position with the following commands:



Test 0



makeatletter
@setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
makeatother


Test 1



setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.


Test 2



setkomavarsignaturehspace26emincludegraphics[width=2.5cm]
example-image


Test 3



setkomavarsignaturehspace26em
beginminipage[t]7cm
Chef Abraracoursix,hfill \Un chef à toujours bras long.
endminipage


But the signature is stuck to the left.
Here is my full code and the result I'm looking for.



% Created 2019-04-08 lun. 11:20
% Intended LaTeX compiler: pdflatex
documentclassscrlttr2
usepackage[francais]babel
usepackage[utf8]inputenc
usepackagehyperref
% usepackageshowframe % to show the page boundaries from https://tex.stackexchange.com/questions/298246/signatures-side-by-side

% usepackagegeometry
% geometryverbose,a4paper,lmargin=3cm,rmargin=3cm

LoadLetterOptionvisualize
showfieldshead,foot,address,location,refline
LoadLetterOptionNF
renewcaptionnamefrenchsubjectnameObjet
renewcaptionnamefrenchccnameC.c.

KOMAoption
,foldmarks=false
,refline=nodate
,subject=titled
,fromemail=false
,fromlogo=false
,fromphone=false
,fromurl=false
,backaddress=false
,foldmarks=false



% from name
setkomavarfromnameChef Abraracoursix
setkomafontfromnamescshape

%%%%%%%%%%%%%%%% HERE %%%%%%%%%%%%%%%%
% signature

%%%% test 1
% setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.

%%%% test 2
% setkomavarsignaturehspace26emincludegraphics[width=2.5cm]example-image% <- changed

%%%% test 3
% setkomavarsignaturehspace26em
% beginminipage[t]7cm
% Chef Abraracoursix,hfill \Un chef à toujours bras long.
% endminipage

%%%% test 4
setkomavarsignature
noindent parbox[t]0.5linewidthChef Abraracoursix,hfill \Un chef à toujours bras long.


%%%%%%%%%%%%%%%% above %%%%%%%%%%%%%%%%


% from adress
setkomavarfromaddressPlace du village,\Erqy,\Armorique
setkomafontfromaddresssmall

% place and location
setkomavarplaceErqy
setkomavarplaceseparator, le

% other komavar
setkomavarccseparator
setkomavar*ccseparatorllapccnamequad
% usepackagesetspace usepackagelipsum setstretch1.15

% setlengthparskipmedskipamount
% setlengthparindent0pt
% setstretch1.15

datetoday

makeatletter
% firsthead
setkomavarfirsthead
usekomafontfromaddress
parbox[b]useplengthfirstheadwidth
usekomafontfromnameusekomavarfromname
hfillusekomafontplaceanddate
ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
usekomavardate

\usekomavarfromaddress
medskip
if@phone\usekomavar*fromphoneusekomavarfromphonefi
if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi
if@fax\usekomavar*fromfaxusekomavarfromfaxfi
if@email\usekomavar*fromemailusekomavarfromemailfi
if@www\usekomavar*fromurlusekomavarfromurlfi



makeatletter
%%%% TEST 0
% @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
makeatother
renewcommand*raggedsignatureraggedright


hypersetup
pdfauthor=Chef Abraracoursix,
pdftitle=Invitation pour une banquet au sanglier Roti,
pdfcreator=Emacs 26.1 (Org mode 9.1.9),
pdflang=French

begindocument

setkomavarsubjectInvitation pour une banquet au sanglier Roti

beginletter
Capitaine Paulus Romanicus\
Camp de Babaorum
Bretany

openingLe Romain,

Dans le cadre des rapports de bon voisinage et de notre hospitalité légendaire, nous vous invitons à festoyer avec nous sous le grand chêne, du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage de la belle Fabala et de vigourix.
closingÀ la tienne !

endletter

enddocument


resulting letter



Idealy I would like



makeatletter
@setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
makeatother


to work as expected with pseudo-lenght given in https://i.stack.imgur.com/D2tu3.png










share|improve this question




























    2















    I'm trying to align the signature with the destination address in a french styled letter.

    I could use the very good lettre class as mentioned in my previous question but I need to scrlttr2 to reuse the org-mode koma export back-end.



    I tried setting the position with the following commands:



    Test 0



    makeatletter
    @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
    makeatother


    Test 1



    setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.


    Test 2



    setkomavarsignaturehspace26emincludegraphics[width=2.5cm]
    example-image


    Test 3



    setkomavarsignaturehspace26em
    beginminipage[t]7cm
    Chef Abraracoursix,hfill \Un chef à toujours bras long.
    endminipage


    But the signature is stuck to the left.
    Here is my full code and the result I'm looking for.



    % Created 2019-04-08 lun. 11:20
    % Intended LaTeX compiler: pdflatex
    documentclassscrlttr2
    usepackage[francais]babel
    usepackage[utf8]inputenc
    usepackagehyperref
    % usepackageshowframe % to show the page boundaries from https://tex.stackexchange.com/questions/298246/signatures-side-by-side

    % usepackagegeometry
    % geometryverbose,a4paper,lmargin=3cm,rmargin=3cm

    LoadLetterOptionvisualize
    showfieldshead,foot,address,location,refline
    LoadLetterOptionNF
    renewcaptionnamefrenchsubjectnameObjet
    renewcaptionnamefrenchccnameC.c.

    KOMAoption
    ,foldmarks=false
    ,refline=nodate
    ,subject=titled
    ,fromemail=false
    ,fromlogo=false
    ,fromphone=false
    ,fromurl=false
    ,backaddress=false
    ,foldmarks=false



    % from name
    setkomavarfromnameChef Abraracoursix
    setkomafontfromnamescshape

    %%%%%%%%%%%%%%%% HERE %%%%%%%%%%%%%%%%
    % signature

    %%%% test 1
    % setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.

    %%%% test 2
    % setkomavarsignaturehspace26emincludegraphics[width=2.5cm]example-image% <- changed

    %%%% test 3
    % setkomavarsignaturehspace26em
    % beginminipage[t]7cm
    % Chef Abraracoursix,hfill \Un chef à toujours bras long.
    % endminipage

    %%%% test 4
    setkomavarsignature
    noindent parbox[t]0.5linewidthChef Abraracoursix,hfill \Un chef à toujours bras long.


    %%%%%%%%%%%%%%%% above %%%%%%%%%%%%%%%%


    % from adress
    setkomavarfromaddressPlace du village,\Erqy,\Armorique
    setkomafontfromaddresssmall

    % place and location
    setkomavarplaceErqy
    setkomavarplaceseparator, le

    % other komavar
    setkomavarccseparator
    setkomavar*ccseparatorllapccnamequad
    % usepackagesetspace usepackagelipsum setstretch1.15

    % setlengthparskipmedskipamount
    % setlengthparindent0pt
    % setstretch1.15

    datetoday

    makeatletter
    % firsthead
    setkomavarfirsthead
    usekomafontfromaddress
    parbox[b]useplengthfirstheadwidth
    usekomafontfromnameusekomavarfromname
    hfillusekomafontplaceanddate
    ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
    usekomavardate

    \usekomavarfromaddress
    medskip
    if@phone\usekomavar*fromphoneusekomavarfromphonefi
    if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi
    if@fax\usekomavar*fromfaxusekomavarfromfaxfi
    if@email\usekomavar*fromemailusekomavarfromemailfi
    if@www\usekomavar*fromurlusekomavarfromurlfi



    makeatletter
    %%%% TEST 0
    % @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
    makeatother
    renewcommand*raggedsignatureraggedright


    hypersetup
    pdfauthor=Chef Abraracoursix,
    pdftitle=Invitation pour une banquet au sanglier Roti,
    pdfcreator=Emacs 26.1 (Org mode 9.1.9),
    pdflang=French

    begindocument

    setkomavarsubjectInvitation pour une banquet au sanglier Roti

    beginletter
    Capitaine Paulus Romanicus\
    Camp de Babaorum
    Bretany

    openingLe Romain,

    Dans le cadre des rapports de bon voisinage et de notre hospitalité légendaire, nous vous invitons à festoyer avec nous sous le grand chêne, du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage de la belle Fabala et de vigourix.
    closingÀ la tienne !

    endletter

    enddocument


    resulting letter



    Idealy I would like



    makeatletter
    @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
    makeatother


    to work as expected with pseudo-lenght given in https://i.stack.imgur.com/D2tu3.png










    share|improve this question


























      2












      2








      2








      I'm trying to align the signature with the destination address in a french styled letter.

      I could use the very good lettre class as mentioned in my previous question but I need to scrlttr2 to reuse the org-mode koma export back-end.



      I tried setting the position with the following commands:



      Test 0



      makeatletter
      @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother


      Test 1



      setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.


      Test 2



      setkomavarsignaturehspace26emincludegraphics[width=2.5cm]
      example-image


      Test 3



      setkomavarsignaturehspace26em
      beginminipage[t]7cm
      Chef Abraracoursix,hfill \Un chef à toujours bras long.
      endminipage


      But the signature is stuck to the left.
      Here is my full code and the result I'm looking for.



      % Created 2019-04-08 lun. 11:20
      % Intended LaTeX compiler: pdflatex
      documentclassscrlttr2
      usepackage[francais]babel
      usepackage[utf8]inputenc
      usepackagehyperref
      % usepackageshowframe % to show the page boundaries from https://tex.stackexchange.com/questions/298246/signatures-side-by-side

      % usepackagegeometry
      % geometryverbose,a4paper,lmargin=3cm,rmargin=3cm

      LoadLetterOptionvisualize
      showfieldshead,foot,address,location,refline
      LoadLetterOptionNF
      renewcaptionnamefrenchsubjectnameObjet
      renewcaptionnamefrenchccnameC.c.

      KOMAoption
      ,foldmarks=false
      ,refline=nodate
      ,subject=titled
      ,fromemail=false
      ,fromlogo=false
      ,fromphone=false
      ,fromurl=false
      ,backaddress=false
      ,foldmarks=false



      % from name
      setkomavarfromnameChef Abraracoursix
      setkomafontfromnamescshape

      %%%%%%%%%%%%%%%% HERE %%%%%%%%%%%%%%%%
      % signature

      %%%% test 1
      % setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.

      %%%% test 2
      % setkomavarsignaturehspace26emincludegraphics[width=2.5cm]example-image% <- changed

      %%%% test 3
      % setkomavarsignaturehspace26em
      % beginminipage[t]7cm
      % Chef Abraracoursix,hfill \Un chef à toujours bras long.
      % endminipage

      %%%% test 4
      setkomavarsignature
      noindent parbox[t]0.5linewidthChef Abraracoursix,hfill \Un chef à toujours bras long.


      %%%%%%%%%%%%%%%% above %%%%%%%%%%%%%%%%


      % from adress
      setkomavarfromaddressPlace du village,\Erqy,\Armorique
      setkomafontfromaddresssmall

      % place and location
      setkomavarplaceErqy
      setkomavarplaceseparator, le

      % other komavar
      setkomavarccseparator
      setkomavar*ccseparatorllapccnamequad
      % usepackagesetspace usepackagelipsum setstretch1.15

      % setlengthparskipmedskipamount
      % setlengthparindent0pt
      % setstretch1.15

      datetoday

      makeatletter
      % firsthead
      setkomavarfirsthead
      usekomafontfromaddress
      parbox[b]useplengthfirstheadwidth
      usekomafontfromnameusekomavarfromname
      hfillusekomafontplaceanddate
      ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
      usekomavardate

      \usekomavarfromaddress
      medskip
      if@phone\usekomavar*fromphoneusekomavarfromphonefi
      if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi
      if@fax\usekomavar*fromfaxusekomavarfromfaxfi
      if@email\usekomavar*fromemailusekomavarfromemailfi
      if@www\usekomavar*fromurlusekomavarfromurlfi



      makeatletter
      %%%% TEST 0
      % @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother
      renewcommand*raggedsignatureraggedright


      hypersetup
      pdfauthor=Chef Abraracoursix,
      pdftitle=Invitation pour une banquet au sanglier Roti,
      pdfcreator=Emacs 26.1 (Org mode 9.1.9),
      pdflang=French

      begindocument

      setkomavarsubjectInvitation pour une banquet au sanglier Roti

      beginletter
      Capitaine Paulus Romanicus\
      Camp de Babaorum
      Bretany

      openingLe Romain,

      Dans le cadre des rapports de bon voisinage et de notre hospitalité légendaire, nous vous invitons à festoyer avec nous sous le grand chêne, du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage de la belle Fabala et de vigourix.
      closingÀ la tienne !

      endletter

      enddocument


      resulting letter



      Idealy I would like



      makeatletter
      @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother


      to work as expected with pseudo-lenght given in https://i.stack.imgur.com/D2tu3.png










      share|improve this question
















      I'm trying to align the signature with the destination address in a french styled letter.

      I could use the very good lettre class as mentioned in my previous question but I need to scrlttr2 to reuse the org-mode koma export back-end.



      I tried setting the position with the following commands:



      Test 0



      makeatletter
      @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother


      Test 1



      setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.


      Test 2



      setkomavarsignaturehspace26emincludegraphics[width=2.5cm]
      example-image


      Test 3



      setkomavarsignaturehspace26em
      beginminipage[t]7cm
      Chef Abraracoursix,hfill \Un chef à toujours bras long.
      endminipage


      But the signature is stuck to the left.
      Here is my full code and the result I'm looking for.



      % Created 2019-04-08 lun. 11:20
      % Intended LaTeX compiler: pdflatex
      documentclassscrlttr2
      usepackage[francais]babel
      usepackage[utf8]inputenc
      usepackagehyperref
      % usepackageshowframe % to show the page boundaries from https://tex.stackexchange.com/questions/298246/signatures-side-by-side

      % usepackagegeometry
      % geometryverbose,a4paper,lmargin=3cm,rmargin=3cm

      LoadLetterOptionvisualize
      showfieldshead,foot,address,location,refline
      LoadLetterOptionNF
      renewcaptionnamefrenchsubjectnameObjet
      renewcaptionnamefrenchccnameC.c.

      KOMAoption
      ,foldmarks=false
      ,refline=nodate
      ,subject=titled
      ,fromemail=false
      ,fromlogo=false
      ,fromphone=false
      ,fromurl=false
      ,backaddress=false
      ,foldmarks=false



      % from name
      setkomavarfromnameChef Abraracoursix
      setkomafontfromnamescshape

      %%%%%%%%%%%%%%%% HERE %%%%%%%%%%%%%%%%
      % signature

      %%%% test 1
      % setkomavarsignatureChef Abraracoursix,\Un chef à toujours bras long.

      %%%% test 2
      % setkomavarsignaturehspace26emincludegraphics[width=2.5cm]example-image% <- changed

      %%%% test 3
      % setkomavarsignaturehspace26em
      % beginminipage[t]7cm
      % Chef Abraracoursix,hfill \Un chef à toujours bras long.
      % endminipage

      %%%% test 4
      setkomavarsignature
      noindent parbox[t]0.5linewidthChef Abraracoursix,hfill \Un chef à toujours bras long.


      %%%%%%%%%%%%%%%% above %%%%%%%%%%%%%%%%


      % from adress
      setkomavarfromaddressPlace du village,\Erqy,\Armorique
      setkomafontfromaddresssmall

      % place and location
      setkomavarplaceErqy
      setkomavarplaceseparator, le

      % other komavar
      setkomavarccseparator
      setkomavar*ccseparatorllapccnamequad
      % usepackagesetspace usepackagelipsum setstretch1.15

      % setlengthparskipmedskipamount
      % setlengthparindent0pt
      % setstretch1.15

      datetoday

      makeatletter
      % firsthead
      setkomavarfirsthead
      usekomafontfromaddress
      parbox[b]useplengthfirstheadwidth
      usekomafontfromnameusekomavarfromname
      hfillusekomafontplaceanddate
      ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
      usekomavardate

      \usekomavarfromaddress
      medskip
      if@phone\usekomavar*fromphoneusekomavarfromphonefi
      if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi
      if@fax\usekomavar*fromfaxusekomavarfromfaxfi
      if@email\usekomavar*fromemailusekomavarfromemailfi
      if@www\usekomavar*fromurlusekomavarfromurlfi



      makeatletter
      %%%% TEST 0
      % @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother
      renewcommand*raggedsignatureraggedright


      hypersetup
      pdfauthor=Chef Abraracoursix,
      pdftitle=Invitation pour une banquet au sanglier Roti,
      pdfcreator=Emacs 26.1 (Org mode 9.1.9),
      pdflang=French

      begindocument

      setkomavarsubjectInvitation pour une banquet au sanglier Roti

      beginletter
      Capitaine Paulus Romanicus\
      Camp de Babaorum
      Bretany

      openingLe Romain,

      Dans le cadre des rapports de bon voisinage et de notre hospitalité légendaire, nous vous invitons à festoyer avec nous sous le grand chêne, du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage de la belle Fabala et de vigourix.
      closingÀ la tienne !

      endletter

      enddocument


      resulting letter



      Idealy I would like



      makeatletter
      @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos}
      makeatother


      to work as expected with pseudo-lenght given in https://i.stack.imgur.com/D2tu3.png







      koma-script letters scrlttr2






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 11 mins ago









      Kurt

      41k950164




      41k950164










      asked 14 hours ago









      Malik KonéMalik Koné

      304




      304




















          2 Answers
          2






          active

          oldest

          votes


















          0














          The problem here is that pseudolength toaddrhpos is set in NF.lco to a negative value of -10mm with command @setplengthtoaddrhpos-10mm.



          That means that the value of 10mm is not the value between left paper side and address field, it is the value between the right paper side and the adress box. Usually the adress box is printed first (on the left side of the paper) and the location box follows then. With file NF-lco that changed as you already showed in your picture in your question.



          sigindent is always calculated from the left side of the typing area, so you have to calculate the needed value for sigindent by yourself.



          One possibility is:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos


          That means we calculate the paperwidth minus toaddrhpos (because its value is already minus we have to use plus here) minus toaddrwidth minus refhpos minus two times toaddrindent.



          With that calculation in your corrected given code



          documentclass[%
          paper=a4,
          fontsize=11pt,
          french,
          ]scrlttr2

          usepackagebabel
          usepackage[T1]fontenc
          usepackage[utf8]inputenc
          usepackagehyperref


          %LoadLetterOptionvisualize
          %showfieldshead,foot,address,location,refline
          LoadLetterOptionNF
          renewcaptionnamefrenchsubjectnameObjet
          renewcaptionnamefrenchccnameC.c.

          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false


          % from name
          setkomavarfromnameChef Abraracoursix
          setkomafontfromnamescshape

          setkomavarsignaturenoindent Chef Abraracoursix,\Un chef à toujours bras long.
          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos % <===============

          % from adress
          setkomavarfromaddressPlace du village,\Erqy,\Armorique
          setkomafontfromaddresssmall

          % place and location
          setkomavarplaceErqy
          setkomavarplaceseparator, le

          % other komavar
          setkomavarccseparator
          setkomavar*ccseparatorllapccnamequad

          datetoday


          % firsthead
          setkomavarfirsthead%
          usekomafontfromaddress%
          parbox[b]useplengthfirstheadwidth%
          usekomafontfromnameusekomavarfromname%
          hfill%
          usekomafontplaceanddate%
          ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
          usekomavardate
          %
          \usekomavarfromaddress%
          medskip
          if@phone\usekomavar*fromphoneusekomavarfromphonefi%
          if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi%
          if@fax\usekomavar*fromfaxusekomavarfromfaxfi%
          if@email\usekomavar*fromemailusekomavarfromemailfi%
          if@www\usekomavar*fromurlusekomavarfromurlfi%
          %


          renewcommand*raggedsignatureraggedright

          hypersetup%
          pdfauthor=Chef Abraracoursix,
          pdftitle=Invitation pour une banquet au sanglier Roti,
          pdfcreator=Emacs 26.1 (Org mode 9.1.9),
          pdflang=French



          begindocument

          setkomavarsubjectInvitation pour une banquet au sanglier Roti

          beginletter%
          Capitaine Paulus Romanicus\
          Camp de Babaorum
          Bretany

          openingLe Romain,

          Dans le cadre des rapports de bon voisinage et de notre hospitalité
          légendaire, nous vous invitons à festoyer avec nous sous le grand chêne,
          du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage
          de la belle Fabala et de vigourix.
          closingÀ la tienne !

          endletter

          enddocument


          you get the following result:



          result



          It seems there is a difference of 5pt too much I do not know where it comes from (rounding errors, an indent I did not saw?). In the case of this mwe you can add them to the calculation with:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos-5pt





          share|improve this answer























          • Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

            – Schweinebacke
            18 mins ago


















          0














          You calculation -useplengthrefhpos+useplengthtoaddhpos does not result in a value, that moves the signature to the middle of the text area.



          In your example the value of refhpos is 0pt and the value of toaddrhpos is -10mm (given by NF.lco). Your



          @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos


          (I've remove one }, which was to much), would result in an sigindent of -10mm. I do not think, that you want this value.



          The image you've linked, is about address fields at the left side. You are using an address field on the right side. So toaddrhpos is the distance from the right paper edge to the right address field edge. It is negative (as told above). The refhpos has nothing to do with the position of the address field.



          Please have a look into part II of the KOMA-Script manual to see, how the values of toaddhpos and refhpos are interpreted by scrlttr2.



          You may try something like:



          setplengthsigindent.5textwidth


          Or a more complicate but correct calculation:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth+useplengthtoaddrindent-oddsidemargin-1in


          Note: This does only work for toaddrhpos < 0.



          paperwidth+useplenthtoaddrhpos is the position of the right edge of the address field relative to the left edge of the paper. Subtracting useplengthtoaddrwidth results in the left edge of the address field relative to the left edge of the paper. Adding useplengthtoaddrindent results in the left edge of the address relative to the left edge of the paper. But sigindent is relative to the left edge of the text area not the paper. So we have to subtract the left margin, which is (in oneside documents for all pages) oddsidemargin+1in.



          Note: Since KOMA-Script 3.26 setplength instead of @setplength is recommended. @setplength is an internal command now. You should not longer use it.



          There are several other issues with your code:




          usepackage[francais]babel



          is deprecated. Current babel warns:




          Package francais.ldf Warning: Option `francais' for Babel is *deprecated*,
          (francais.ldf) it might be removed sooner or later. Please
          (francais.ldf) use `french' instead; reported on input line 31.






          KOMAoption
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false




          is wrong. KOMAoption has two arguments. The first one is an option key, the second is a list of option values.



          To help users to find out what's wrong, the current prerelease of KOMA-Script shows the following error message with your wrong usage of KOMAoption:




          ./test.tex:28: Package scrbase Error: syntax error in key ` ,foldmarks=false ,r
          efline=nodate ,subject=titled ,fromemail=false ,fromlogo=false ,fromphone=false
          ,fromurl=false ,backaddress=false ,foldmarks=false '.

          See the scrbase package documentation for explanation.
          Type H <return> for immediate help.
          ...

          l.28 }

          You've used `...Option' to set the key ` ,foldmarks=false ,refline=nodate ,sub
          ject=titled ,fromemail=false ,fromlogo=false ,fromphone=false ,fromurl=false ,b
          ackaddress=false ,foldmarks=false '
          to new value(s), but `,' is not allowed in the key of an option
          (and `...Option' does not use `,' to separate several keys).
          Maybe you've meant ...Options instead of ...Option.
          If you'll continue, I'll give it a try, but you should expect further
          and even strange error messages.



          As the help text of the error message explains:



          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false



          would be correct.



          Your definition of firsthead adds several significant but unwanted white spaces. See What is the use of percent signs (%) at the end of lines? for more information how to avoid them.



          Last but not least, you have a




          makeatletter



          instead of



          makeatletter


          in your document preamble.






          share|improve this answer

























          • I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

            – Malik Koné
            8 hours ago











          • As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

            – Schweinebacke
            22 mins ago











          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "85"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483809%2fthe-scrlttr2-signature-position-with-koma-script-pseudolength-sigindent%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          2 Answers
          2






          active

          oldest

          votes








          2 Answers
          2






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0














          The problem here is that pseudolength toaddrhpos is set in NF.lco to a negative value of -10mm with command @setplengthtoaddrhpos-10mm.



          That means that the value of 10mm is not the value between left paper side and address field, it is the value between the right paper side and the adress box. Usually the adress box is printed first (on the left side of the paper) and the location box follows then. With file NF-lco that changed as you already showed in your picture in your question.



          sigindent is always calculated from the left side of the typing area, so you have to calculate the needed value for sigindent by yourself.



          One possibility is:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos


          That means we calculate the paperwidth minus toaddrhpos (because its value is already minus we have to use plus here) minus toaddrwidth minus refhpos minus two times toaddrindent.



          With that calculation in your corrected given code



          documentclass[%
          paper=a4,
          fontsize=11pt,
          french,
          ]scrlttr2

          usepackagebabel
          usepackage[T1]fontenc
          usepackage[utf8]inputenc
          usepackagehyperref


          %LoadLetterOptionvisualize
          %showfieldshead,foot,address,location,refline
          LoadLetterOptionNF
          renewcaptionnamefrenchsubjectnameObjet
          renewcaptionnamefrenchccnameC.c.

          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false


          % from name
          setkomavarfromnameChef Abraracoursix
          setkomafontfromnamescshape

          setkomavarsignaturenoindent Chef Abraracoursix,\Un chef à toujours bras long.
          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos % <===============

          % from adress
          setkomavarfromaddressPlace du village,\Erqy,\Armorique
          setkomafontfromaddresssmall

          % place and location
          setkomavarplaceErqy
          setkomavarplaceseparator, le

          % other komavar
          setkomavarccseparator
          setkomavar*ccseparatorllapccnamequad

          datetoday


          % firsthead
          setkomavarfirsthead%
          usekomafontfromaddress%
          parbox[b]useplengthfirstheadwidth%
          usekomafontfromnameusekomavarfromname%
          hfill%
          usekomafontplaceanddate%
          ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
          usekomavardate
          %
          \usekomavarfromaddress%
          medskip
          if@phone\usekomavar*fromphoneusekomavarfromphonefi%
          if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi%
          if@fax\usekomavar*fromfaxusekomavarfromfaxfi%
          if@email\usekomavar*fromemailusekomavarfromemailfi%
          if@www\usekomavar*fromurlusekomavarfromurlfi%
          %


          renewcommand*raggedsignatureraggedright

          hypersetup%
          pdfauthor=Chef Abraracoursix,
          pdftitle=Invitation pour une banquet au sanglier Roti,
          pdfcreator=Emacs 26.1 (Org mode 9.1.9),
          pdflang=French



          begindocument

          setkomavarsubjectInvitation pour une banquet au sanglier Roti

          beginletter%
          Capitaine Paulus Romanicus\
          Camp de Babaorum
          Bretany

          openingLe Romain,

          Dans le cadre des rapports de bon voisinage et de notre hospitalité
          légendaire, nous vous invitons à festoyer avec nous sous le grand chêne,
          du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage
          de la belle Fabala et de vigourix.
          closingÀ la tienne !

          endletter

          enddocument


          you get the following result:



          result



          It seems there is a difference of 5pt too much I do not know where it comes from (rounding errors, an indent I did not saw?). In the case of this mwe you can add them to the calculation with:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos-5pt





          share|improve this answer























          • Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

            – Schweinebacke
            18 mins ago















          0














          The problem here is that pseudolength toaddrhpos is set in NF.lco to a negative value of -10mm with command @setplengthtoaddrhpos-10mm.



          That means that the value of 10mm is not the value between left paper side and address field, it is the value between the right paper side and the adress box. Usually the adress box is printed first (on the left side of the paper) and the location box follows then. With file NF-lco that changed as you already showed in your picture in your question.



          sigindent is always calculated from the left side of the typing area, so you have to calculate the needed value for sigindent by yourself.



          One possibility is:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos


          That means we calculate the paperwidth minus toaddrhpos (because its value is already minus we have to use plus here) minus toaddrwidth minus refhpos minus two times toaddrindent.



          With that calculation in your corrected given code



          documentclass[%
          paper=a4,
          fontsize=11pt,
          french,
          ]scrlttr2

          usepackagebabel
          usepackage[T1]fontenc
          usepackage[utf8]inputenc
          usepackagehyperref


          %LoadLetterOptionvisualize
          %showfieldshead,foot,address,location,refline
          LoadLetterOptionNF
          renewcaptionnamefrenchsubjectnameObjet
          renewcaptionnamefrenchccnameC.c.

          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false


          % from name
          setkomavarfromnameChef Abraracoursix
          setkomafontfromnamescshape

          setkomavarsignaturenoindent Chef Abraracoursix,\Un chef à toujours bras long.
          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos % <===============

          % from adress
          setkomavarfromaddressPlace du village,\Erqy,\Armorique
          setkomafontfromaddresssmall

          % place and location
          setkomavarplaceErqy
          setkomavarplaceseparator, le

          % other komavar
          setkomavarccseparator
          setkomavar*ccseparatorllapccnamequad

          datetoday


          % firsthead
          setkomavarfirsthead%
          usekomafontfromaddress%
          parbox[b]useplengthfirstheadwidth%
          usekomafontfromnameusekomavarfromname%
          hfill%
          usekomafontplaceanddate%
          ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
          usekomavardate
          %
          \usekomavarfromaddress%
          medskip
          if@phone\usekomavar*fromphoneusekomavarfromphonefi%
          if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi%
          if@fax\usekomavar*fromfaxusekomavarfromfaxfi%
          if@email\usekomavar*fromemailusekomavarfromemailfi%
          if@www\usekomavar*fromurlusekomavarfromurlfi%
          %


          renewcommand*raggedsignatureraggedright

          hypersetup%
          pdfauthor=Chef Abraracoursix,
          pdftitle=Invitation pour une banquet au sanglier Roti,
          pdfcreator=Emacs 26.1 (Org mode 9.1.9),
          pdflang=French



          begindocument

          setkomavarsubjectInvitation pour une banquet au sanglier Roti

          beginletter%
          Capitaine Paulus Romanicus\
          Camp de Babaorum
          Bretany

          openingLe Romain,

          Dans le cadre des rapports de bon voisinage et de notre hospitalité
          légendaire, nous vous invitons à festoyer avec nous sous le grand chêne,
          du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage
          de la belle Fabala et de vigourix.
          closingÀ la tienne !

          endletter

          enddocument


          you get the following result:



          result



          It seems there is a difference of 5pt too much I do not know where it comes from (rounding errors, an indent I did not saw?). In the case of this mwe you can add them to the calculation with:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos-5pt





          share|improve this answer























          • Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

            – Schweinebacke
            18 mins ago













          0












          0








          0







          The problem here is that pseudolength toaddrhpos is set in NF.lco to a negative value of -10mm with command @setplengthtoaddrhpos-10mm.



          That means that the value of 10mm is not the value between left paper side and address field, it is the value between the right paper side and the adress box. Usually the adress box is printed first (on the left side of the paper) and the location box follows then. With file NF-lco that changed as you already showed in your picture in your question.



          sigindent is always calculated from the left side of the typing area, so you have to calculate the needed value for sigindent by yourself.



          One possibility is:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos


          That means we calculate the paperwidth minus toaddrhpos (because its value is already minus we have to use plus here) minus toaddrwidth minus refhpos minus two times toaddrindent.



          With that calculation in your corrected given code



          documentclass[%
          paper=a4,
          fontsize=11pt,
          french,
          ]scrlttr2

          usepackagebabel
          usepackage[T1]fontenc
          usepackage[utf8]inputenc
          usepackagehyperref


          %LoadLetterOptionvisualize
          %showfieldshead,foot,address,location,refline
          LoadLetterOptionNF
          renewcaptionnamefrenchsubjectnameObjet
          renewcaptionnamefrenchccnameC.c.

          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false


          % from name
          setkomavarfromnameChef Abraracoursix
          setkomafontfromnamescshape

          setkomavarsignaturenoindent Chef Abraracoursix,\Un chef à toujours bras long.
          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos % <===============

          % from adress
          setkomavarfromaddressPlace du village,\Erqy,\Armorique
          setkomafontfromaddresssmall

          % place and location
          setkomavarplaceErqy
          setkomavarplaceseparator, le

          % other komavar
          setkomavarccseparator
          setkomavar*ccseparatorllapccnamequad

          datetoday


          % firsthead
          setkomavarfirsthead%
          usekomafontfromaddress%
          parbox[b]useplengthfirstheadwidth%
          usekomafontfromnameusekomavarfromname%
          hfill%
          usekomafontplaceanddate%
          ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
          usekomavardate
          %
          \usekomavarfromaddress%
          medskip
          if@phone\usekomavar*fromphoneusekomavarfromphonefi%
          if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi%
          if@fax\usekomavar*fromfaxusekomavarfromfaxfi%
          if@email\usekomavar*fromemailusekomavarfromemailfi%
          if@www\usekomavar*fromurlusekomavarfromurlfi%
          %


          renewcommand*raggedsignatureraggedright

          hypersetup%
          pdfauthor=Chef Abraracoursix,
          pdftitle=Invitation pour une banquet au sanglier Roti,
          pdfcreator=Emacs 26.1 (Org mode 9.1.9),
          pdflang=French



          begindocument

          setkomavarsubjectInvitation pour une banquet au sanglier Roti

          beginletter%
          Capitaine Paulus Romanicus\
          Camp de Babaorum
          Bretany

          openingLe Romain,

          Dans le cadre des rapports de bon voisinage et de notre hospitalité
          légendaire, nous vous invitons à festoyer avec nous sous le grand chêne,
          du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage
          de la belle Fabala et de vigourix.
          closingÀ la tienne !

          endletter

          enddocument


          you get the following result:



          result



          It seems there is a difference of 5pt too much I do not know where it comes from (rounding errors, an indent I did not saw?). In the case of this mwe you can add them to the calculation with:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos-5pt





          share|improve this answer













          The problem here is that pseudolength toaddrhpos is set in NF.lco to a negative value of -10mm with command @setplengthtoaddrhpos-10mm.



          That means that the value of 10mm is not the value between left paper side and address field, it is the value between the right paper side and the adress box. Usually the adress box is printed first (on the left side of the paper) and the location box follows then. With file NF-lco that changed as you already showed in your picture in your question.



          sigindent is always calculated from the left side of the typing area, so you have to calculate the needed value for sigindent by yourself.



          One possibility is:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos


          That means we calculate the paperwidth minus toaddrhpos (because its value is already minus we have to use plus here) minus toaddrwidth minus refhpos minus two times toaddrindent.



          With that calculation in your corrected given code



          documentclass[%
          paper=a4,
          fontsize=11pt,
          french,
          ]scrlttr2

          usepackagebabel
          usepackage[T1]fontenc
          usepackage[utf8]inputenc
          usepackagehyperref


          %LoadLetterOptionvisualize
          %showfieldshead,foot,address,location,refline
          LoadLetterOptionNF
          renewcaptionnamefrenchsubjectnameObjet
          renewcaptionnamefrenchccnameC.c.

          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false


          % from name
          setkomavarfromnameChef Abraracoursix
          setkomafontfromnamescshape

          setkomavarsignaturenoindent Chef Abraracoursix,\Un chef à toujours bras long.
          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos % <===============

          % from adress
          setkomavarfromaddressPlace du village,\Erqy,\Armorique
          setkomafontfromaddresssmall

          % place and location
          setkomavarplaceErqy
          setkomavarplaceseparator, le

          % other komavar
          setkomavarccseparator
          setkomavar*ccseparatorllapccnamequad

          datetoday


          % firsthead
          setkomavarfirsthead%
          usekomafontfromaddress%
          parbox[b]useplengthfirstheadwidth%
          usekomafontfromnameusekomavarfromname%
          hfill%
          usekomafontplaceanddate%
          ifkomavaremptyplaceusekomavarplaceusekomavarplaceseparator
          usekomavardate
          %
          \usekomavarfromaddress%
          medskip
          if@phone\usekomavar*fromphoneusekomavarfromphonefi%
          if@mobilephone\usekomavar*frommobilephoneusekomavarfrommobilephonefi%
          if@fax\usekomavar*fromfaxusekomavarfromfaxfi%
          if@email\usekomavar*fromemailusekomavarfromemailfi%
          if@www\usekomavar*fromurlusekomavarfromurlfi%
          %


          renewcommand*raggedsignatureraggedright

          hypersetup%
          pdfauthor=Chef Abraracoursix,
          pdftitle=Invitation pour une banquet au sanglier Roti,
          pdfcreator=Emacs 26.1 (Org mode 9.1.9),
          pdflang=French



          begindocument

          setkomavarsubjectInvitation pour une banquet au sanglier Roti

          beginletter%
          Capitaine Paulus Romanicus\
          Camp de Babaorum
          Bretany

          openingLe Romain,

          Dans le cadre des rapports de bon voisinage et de notre hospitalité
          légendaire, nous vous invitons à festoyer avec nous sous le grand chêne,
          du coucher du soleil à l'aube, à la prochaine plein lune pour le mariage
          de la belle Fabala et de vigourix.
          closingÀ la tienne !

          endletter

          enddocument


          you get the following result:



          result



          It seems there is a difference of 5pt too much I do not know where it comes from (rounding errors, an indent I did not saw?). In the case of this mwe you can add them to the calculation with:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth-useplengthtoaddrindent-useplengthtoaddrindent-useplengthrefhpos-5pt






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 22 mins ago









          KurtKurt

          41k950164




          41k950164












          • Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

            – Schweinebacke
            18 mins ago

















          • Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

            – Schweinebacke
            18 mins ago
















          Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

          – Schweinebacke
          18 mins ago





          Your calculation is wrong. todaddrindent has to be added not subtracted. refhpos has nothing to do with the position of the address (btw it is 0 as I told in my answer) and you have not take into account, that toaddhpos is relative to the paper edge while sigindent is relative to the text area edge. So again for the correct value see my answer.

          – Schweinebacke
          18 mins ago











          0














          You calculation -useplengthrefhpos+useplengthtoaddhpos does not result in a value, that moves the signature to the middle of the text area.



          In your example the value of refhpos is 0pt and the value of toaddrhpos is -10mm (given by NF.lco). Your



          @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos


          (I've remove one }, which was to much), would result in an sigindent of -10mm. I do not think, that you want this value.



          The image you've linked, is about address fields at the left side. You are using an address field on the right side. So toaddrhpos is the distance from the right paper edge to the right address field edge. It is negative (as told above). The refhpos has nothing to do with the position of the address field.



          Please have a look into part II of the KOMA-Script manual to see, how the values of toaddhpos and refhpos are interpreted by scrlttr2.



          You may try something like:



          setplengthsigindent.5textwidth


          Or a more complicate but correct calculation:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth+useplengthtoaddrindent-oddsidemargin-1in


          Note: This does only work for toaddrhpos < 0.



          paperwidth+useplenthtoaddrhpos is the position of the right edge of the address field relative to the left edge of the paper. Subtracting useplengthtoaddrwidth results in the left edge of the address field relative to the left edge of the paper. Adding useplengthtoaddrindent results in the left edge of the address relative to the left edge of the paper. But sigindent is relative to the left edge of the text area not the paper. So we have to subtract the left margin, which is (in oneside documents for all pages) oddsidemargin+1in.



          Note: Since KOMA-Script 3.26 setplength instead of @setplength is recommended. @setplength is an internal command now. You should not longer use it.



          There are several other issues with your code:




          usepackage[francais]babel



          is deprecated. Current babel warns:




          Package francais.ldf Warning: Option `francais' for Babel is *deprecated*,
          (francais.ldf) it might be removed sooner or later. Please
          (francais.ldf) use `french' instead; reported on input line 31.






          KOMAoption
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false




          is wrong. KOMAoption has two arguments. The first one is an option key, the second is a list of option values.



          To help users to find out what's wrong, the current prerelease of KOMA-Script shows the following error message with your wrong usage of KOMAoption:




          ./test.tex:28: Package scrbase Error: syntax error in key ` ,foldmarks=false ,r
          efline=nodate ,subject=titled ,fromemail=false ,fromlogo=false ,fromphone=false
          ,fromurl=false ,backaddress=false ,foldmarks=false '.

          See the scrbase package documentation for explanation.
          Type H <return> for immediate help.
          ...

          l.28 }

          You've used `...Option' to set the key ` ,foldmarks=false ,refline=nodate ,sub
          ject=titled ,fromemail=false ,fromlogo=false ,fromphone=false ,fromurl=false ,b
          ackaddress=false ,foldmarks=false '
          to new value(s), but `,' is not allowed in the key of an option
          (and `...Option' does not use `,' to separate several keys).
          Maybe you've meant ...Options instead of ...Option.
          If you'll continue, I'll give it a try, but you should expect further
          and even strange error messages.



          As the help text of the error message explains:



          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false



          would be correct.



          Your definition of firsthead adds several significant but unwanted white spaces. See What is the use of percent signs (%) at the end of lines? for more information how to avoid them.



          Last but not least, you have a




          makeatletter



          instead of



          makeatletter


          in your document preamble.






          share|improve this answer

























          • I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

            – Malik Koné
            8 hours ago











          • As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

            – Schweinebacke
            22 mins ago















          0














          You calculation -useplengthrefhpos+useplengthtoaddhpos does not result in a value, that moves the signature to the middle of the text area.



          In your example the value of refhpos is 0pt and the value of toaddrhpos is -10mm (given by NF.lco). Your



          @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos


          (I've remove one }, which was to much), would result in an sigindent of -10mm. I do not think, that you want this value.



          The image you've linked, is about address fields at the left side. You are using an address field on the right side. So toaddrhpos is the distance from the right paper edge to the right address field edge. It is negative (as told above). The refhpos has nothing to do with the position of the address field.



          Please have a look into part II of the KOMA-Script manual to see, how the values of toaddhpos and refhpos are interpreted by scrlttr2.



          You may try something like:



          setplengthsigindent.5textwidth


          Or a more complicate but correct calculation:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth+useplengthtoaddrindent-oddsidemargin-1in


          Note: This does only work for toaddrhpos < 0.



          paperwidth+useplenthtoaddrhpos is the position of the right edge of the address field relative to the left edge of the paper. Subtracting useplengthtoaddrwidth results in the left edge of the address field relative to the left edge of the paper. Adding useplengthtoaddrindent results in the left edge of the address relative to the left edge of the paper. But sigindent is relative to the left edge of the text area not the paper. So we have to subtract the left margin, which is (in oneside documents for all pages) oddsidemargin+1in.



          Note: Since KOMA-Script 3.26 setplength instead of @setplength is recommended. @setplength is an internal command now. You should not longer use it.



          There are several other issues with your code:




          usepackage[francais]babel



          is deprecated. Current babel warns:




          Package francais.ldf Warning: Option `francais' for Babel is *deprecated*,
          (francais.ldf) it might be removed sooner or later. Please
          (francais.ldf) use `french' instead; reported on input line 31.






          KOMAoption
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false




          is wrong. KOMAoption has two arguments. The first one is an option key, the second is a list of option values.



          To help users to find out what's wrong, the current prerelease of KOMA-Script shows the following error message with your wrong usage of KOMAoption:




          ./test.tex:28: Package scrbase Error: syntax error in key ` ,foldmarks=false ,r
          efline=nodate ,subject=titled ,fromemail=false ,fromlogo=false ,fromphone=false
          ,fromurl=false ,backaddress=false ,foldmarks=false '.

          See the scrbase package documentation for explanation.
          Type H <return> for immediate help.
          ...

          l.28 }

          You've used `...Option' to set the key ` ,foldmarks=false ,refline=nodate ,sub
          ject=titled ,fromemail=false ,fromlogo=false ,fromphone=false ,fromurl=false ,b
          ackaddress=false ,foldmarks=false '
          to new value(s), but `,' is not allowed in the key of an option
          (and `...Option' does not use `,' to separate several keys).
          Maybe you've meant ...Options instead of ...Option.
          If you'll continue, I'll give it a try, but you should expect further
          and even strange error messages.



          As the help text of the error message explains:



          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false



          would be correct.



          Your definition of firsthead adds several significant but unwanted white spaces. See What is the use of percent signs (%) at the end of lines? for more information how to avoid them.



          Last but not least, you have a




          makeatletter



          instead of



          makeatletter


          in your document preamble.






          share|improve this answer

























          • I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

            – Malik Koné
            8 hours ago











          • As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

            – Schweinebacke
            22 mins ago













          0












          0








          0







          You calculation -useplengthrefhpos+useplengthtoaddhpos does not result in a value, that moves the signature to the middle of the text area.



          In your example the value of refhpos is 0pt and the value of toaddrhpos is -10mm (given by NF.lco). Your



          @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos


          (I've remove one }, which was to much), would result in an sigindent of -10mm. I do not think, that you want this value.



          The image you've linked, is about address fields at the left side. You are using an address field on the right side. So toaddrhpos is the distance from the right paper edge to the right address field edge. It is negative (as told above). The refhpos has nothing to do with the position of the address field.



          Please have a look into part II of the KOMA-Script manual to see, how the values of toaddhpos and refhpos are interpreted by scrlttr2.



          You may try something like:



          setplengthsigindent.5textwidth


          Or a more complicate but correct calculation:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth+useplengthtoaddrindent-oddsidemargin-1in


          Note: This does only work for toaddrhpos < 0.



          paperwidth+useplenthtoaddrhpos is the position of the right edge of the address field relative to the left edge of the paper. Subtracting useplengthtoaddrwidth results in the left edge of the address field relative to the left edge of the paper. Adding useplengthtoaddrindent results in the left edge of the address relative to the left edge of the paper. But sigindent is relative to the left edge of the text area not the paper. So we have to subtract the left margin, which is (in oneside documents for all pages) oddsidemargin+1in.



          Note: Since KOMA-Script 3.26 setplength instead of @setplength is recommended. @setplength is an internal command now. You should not longer use it.



          There are several other issues with your code:




          usepackage[francais]babel



          is deprecated. Current babel warns:




          Package francais.ldf Warning: Option `francais' for Babel is *deprecated*,
          (francais.ldf) it might be removed sooner or later. Please
          (francais.ldf) use `french' instead; reported on input line 31.






          KOMAoption
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false




          is wrong. KOMAoption has two arguments. The first one is an option key, the second is a list of option values.



          To help users to find out what's wrong, the current prerelease of KOMA-Script shows the following error message with your wrong usage of KOMAoption:




          ./test.tex:28: Package scrbase Error: syntax error in key ` ,foldmarks=false ,r
          efline=nodate ,subject=titled ,fromemail=false ,fromlogo=false ,fromphone=false
          ,fromurl=false ,backaddress=false ,foldmarks=false '.

          See the scrbase package documentation for explanation.
          Type H <return> for immediate help.
          ...

          l.28 }

          You've used `...Option' to set the key ` ,foldmarks=false ,refline=nodate ,sub
          ject=titled ,fromemail=false ,fromlogo=false ,fromphone=false ,fromurl=false ,b
          ackaddress=false ,foldmarks=false '
          to new value(s), but `,' is not allowed in the key of an option
          (and `...Option' does not use `,' to separate several keys).
          Maybe you've meant ...Options instead of ...Option.
          If you'll continue, I'll give it a try, but you should expect further
          and even strange error messages.



          As the help text of the error message explains:



          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false



          would be correct.



          Your definition of firsthead adds several significant but unwanted white spaces. See What is the use of percent signs (%) at the end of lines? for more information how to avoid them.



          Last but not least, you have a




          makeatletter



          instead of



          makeatletter


          in your document preamble.






          share|improve this answer















          You calculation -useplengthrefhpos+useplengthtoaddhpos does not result in a value, that moves the signature to the middle of the text area.



          In your example the value of refhpos is 0pt and the value of toaddrhpos is -10mm (given by NF.lco). Your



          @setplengthsigindent-useplengthrefhpos+useplengthtoaddrhpos


          (I've remove one }, which was to much), would result in an sigindent of -10mm. I do not think, that you want this value.



          The image you've linked, is about address fields at the left side. You are using an address field on the right side. So toaddrhpos is the distance from the right paper edge to the right address field edge. It is negative (as told above). The refhpos has nothing to do with the position of the address field.



          Please have a look into part II of the KOMA-Script manual to see, how the values of toaddhpos and refhpos are interpreted by scrlttr2.



          You may try something like:



          setplengthsigindent.5textwidth


          Or a more complicate but correct calculation:



          setplengthsigindentpaperwidth+useplengthtoaddrhpos-useplengthtoaddrwidth+useplengthtoaddrindent-oddsidemargin-1in


          Note: This does only work for toaddrhpos < 0.



          paperwidth+useplenthtoaddrhpos is the position of the right edge of the address field relative to the left edge of the paper. Subtracting useplengthtoaddrwidth results in the left edge of the address field relative to the left edge of the paper. Adding useplengthtoaddrindent results in the left edge of the address relative to the left edge of the paper. But sigindent is relative to the left edge of the text area not the paper. So we have to subtract the left margin, which is (in oneside documents for all pages) oddsidemargin+1in.



          Note: Since KOMA-Script 3.26 setplength instead of @setplength is recommended. @setplength is an internal command now. You should not longer use it.



          There are several other issues with your code:




          usepackage[francais]babel



          is deprecated. Current babel warns:




          Package francais.ldf Warning: Option `francais' for Babel is *deprecated*,
          (francais.ldf) it might be removed sooner or later. Please
          (francais.ldf) use `french' instead; reported on input line 31.






          KOMAoption
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false




          is wrong. KOMAoption has two arguments. The first one is an option key, the second is a list of option values.



          To help users to find out what's wrong, the current prerelease of KOMA-Script shows the following error message with your wrong usage of KOMAoption:




          ./test.tex:28: Package scrbase Error: syntax error in key ` ,foldmarks=false ,r
          efline=nodate ,subject=titled ,fromemail=false ,fromlogo=false ,fromphone=false
          ,fromurl=false ,backaddress=false ,foldmarks=false '.

          See the scrbase package documentation for explanation.
          Type H <return> for immediate help.
          ...

          l.28 }

          You've used `...Option' to set the key ` ,foldmarks=false ,refline=nodate ,sub
          ject=titled ,fromemail=false ,fromlogo=false ,fromphone=false ,fromurl=false ,b
          ackaddress=false ,foldmarks=false '
          to new value(s), but `,' is not allowed in the key of an option
          (and `...Option' does not use `,' to separate several keys).
          Maybe you've meant ...Options instead of ...Option.
          If you'll continue, I'll give it a try, but you should expect further
          and even strange error messages.



          As the help text of the error message explains:



          KOMAoptions
          ,foldmarks=false
          ,refline=nodate
          ,subject=titled
          ,fromemail=false
          ,fromlogo=false
          ,fromphone=false
          ,fromurl=false
          ,backaddress=false
          ,foldmarks=false



          would be correct.



          Your definition of firsthead adds several significant but unwanted white spaces. See What is the use of percent signs (%) at the end of lines? for more information how to avoid them.



          Last but not least, you have a




          makeatletter



          instead of



          makeatletter


          in your document preamble.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited 11 mins ago

























          answered 12 hours ago









          SchweinebackeSchweinebacke

          22.3k4577




          22.3k4577












          • I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

            – Malik Koné
            8 hours ago











          • As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

            – Schweinebacke
            22 mins ago

















          • I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

            – Malik Koné
            8 hours ago











          • As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

            – Schweinebacke
            22 mins ago
















          I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

          – Malik Koné
          8 hours ago





          I provided the link to the pseudo-lengths i.stack.imgur.com/D2tu3.png for a letter where what I want is clearly - refhpos + toaddhpos. What I don't understand is why all the above command have not impact on my signature's position.

          – Malik Koné
          8 hours ago













          As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

          – Schweinebacke
          22 mins ago





          As I told you: Your calculation refhpos + toaddhpos results in -10mm which is wrong. Try the two suggestions I made. The second one should be exactly what you are searching for. BTW: The picture is from the KOMA-Script manual. I know that picture.

          – Schweinebacke
          22 mins ago

















          draft saved

          draft discarded
















































          Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483809%2fthe-scrlttr2-signature-position-with-koma-script-pseudolength-sigindent%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Isabella Eugénie Boyer Biographie | Références | Menu de navigationmodifiermodifier le codeComparator to Compute the Relative Value of a U.S. Dollar Amount – 1774 to Present.

          Lioubotyn Sommaire Géographie | Histoire | Population | Notes et références | Liens externes | Menu de navigationlubotin.kharkov.uamodifier« Recensements et estimations de la population depuis 1897 »« Office des statistiques d'Ukraine : population au 1er janvier 2010, 2011 et 2012 »« Office des statistiques d'Ukraine : population au 1er janvier 2011, 2012 et 2013 »Informations officiellesCartes topographiquesCarte routièrem

          Mpande kaSenzangakhona Biographie | Références | Menu de navigationmodifierMpande kaSenzangakhonavoir la liste des auteursm