Locator in nested Manipulates
- To: mathgroup at smc.vnet.net
- Subject: [mg123394] Locator in nested Manipulates
- From: Chris Young <cy56 at comcast.net>
- Date: Mon, 5 Dec 2011 05:16:23 -0500 (EST)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
I was hoping that I could add a Locator control to the original
Manipulator pane by using another enclosing Manipulator, but the p
Locator is restricted to a small corner outside of the original pane.
Taking the p control out of original contourPlot routine
contourPlot[f_] :=
Manipulate[
ContourPlot[
f,
{x, -5, 5}, {y, -4, 4},
Contours -> contours,
PlotPoints -> plotPts,
MaxRecursion -> maxRecurs,
Axes -> True,
ImageSize -> {300, 4/5 300},
AspectRatio -> 4/5
],
{{contours, 5}, 0, 80, 5},
{{plotPts, 20}, 10, 80, 5},
{{maxRecurs, 1}, 1, 10, 1}
]
Manipulate[
contourPlot[
Arg @ ((x + I y) - (p[[1]] + p[[2]] I)) ((x + I y) + (p[[1]] +
p[[2]] I))],
{{p, {1, 1}}, Locator}
]