AcroTeX • eforms • lengths • Add tags Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
6 posts • Page 1 of 1
I am using the package eforms as found in the AcroTex bundle. With it, I am trying to make an electronic form in which the user fills out text fields. With
Where I run into trouble is the length of the text box. The way that I would like the form to look is as follows:
where the underline section is where the interactive text field exists. As the command
Does anyone have any ideas on how I can get a text box to stretch the remaining length of the page?
Last edited by cgnieder on Thu Aug 29th, 2013, edited 3 times in total.
Reason: added inline code markup
in the code below I defined a command \MyField that solves your problem:
Feel free to modify my example to suit your needs.
Just to clarify the herein provided solution:
You don't actually measure the remaining of the current line, you measure the beginning of the line and subtract it from
At least that's what the example code does. I don't know if there is actually a way to get the remainder of the line. I feel like it should be possible b/c LaTeX needs to know. How else could it produce the wonderful "
I have been studying gmedina's code to try to solve a slightly different problem but with no answer yet - perhaps some kind soul out there can help me.
I am a lecturer and have an issue when compiling test and exam questions. The question looks something like this, where the marks shown in brackets are right justified on the last line of the problem:
Is there a way to measure the remaining space on a line and simultaneously measure the length of the marks bracket, then, in the case where the marks bracket length is larger than the remaining space get the marks bracket to right justify on the succeeding line. Note that the exact length of the marks bracket varies (consider the lengths of "(1 mark)" and "(20 marks)" and the exact text of the last line is not known until the text is compiled (as compared rhino7890's example where the exact text is known).
Thanks for your assistance.
Last edited by cgnieder on Thu Aug 29th, 2013, edited 1 time in total.
Reason: added code markup
instead of adding a new post to a thread that has been marked as solved it would have been better to start a new thread. You could have referred to this thread by linking to it.
To me it seams you're setting various details of your exams by hand. Have you considered using a dedicated package or class such as exam, answers, probsoln or exsheets?
6 posts • Page 1 of 1
Topic TagsAcroTeX • eforms • lengths
Users browsing this forum: No registered users and 4 guests