# InputField AutoSize Speed Issue

How do I have an InputField adjust to fill the remaining size of the window automatically? For example:

Using the ImageSize option often either freezes or takes 5 seconds or longer to run in Mathematica 8.0 in Windows 7. No longer an issue.

-
If characters are fixed-width, find out the width of a character and divide by this? – shrx Jun 17 '13 at 21:47
@shrx With all the different Unicode variations, or even a common example for mathemaiica users the -> I can't really imagine the InputField contain a fixed width font, but I could be wrong. – William Jun 17 '13 at 22:40
Have you tried the ImageSize option for InputField? – Silvia Jun 17 '13 at 23:05
@Silvia ImageSize just seems to take forever to evaluate in mathematica for me. I am going to edit the question example that shows the speed issues. – William Jun 17 '13 at 23:16
Hmm... I didn't encounter any speed issue with that option. Could you describe your issues more precisely? – Silvia Jun 17 '13 at 23:19

Not sure if 124px as the difference will work in all Operating System, but it certainly seems to work in Windows 7 M8.0.

width1 = 100;
width = Dynamic[(WindowSize /.
Options[SelectedNotebook[], WindowSize])[[1]]];
Grid[{{
InputField["fixed", String,
ImageSize -> {width1, Automatic}],
InputField["dynamic", String,
ImageSize -> {Dynamic[width] - 124 - width1, Automatic}]
}}]

-