From: Frank Gruendel (fg2_at_pda-soft.de)
Date: Sun Feb 09 2003 - 17:22:57 PST
Hi all,
sorry for the longish listing that is (I am aware of that)
unimportant for most.
Could some kind NewtonScript expert please have a look at
the following code and tell me why I don't see my subview
on any Newton running os 1.3 or earlier before I run head-first
against a wall, thus ending any more futile attempts at writing
cool Newton software?
Basically, my main view is a protoFloatNGo. It's child is a clView,
inside this clView is another clView that contains a button and
a close box. Looks as expected on all Newtons with os 2.0 or later,
but I can't see the innermost clView on Newtons running os 1.3 or
earlier. It is there, though, the button and the closebox can be
clicked (if you find them) and behave as expected. Also, their
highlighted state is painted.
I tried to leave out the middle clView, instead adding the view
with button and close box directly to the main view. This works as
expected.
Thanks (going to sleep now. Grr...)
Frank
// Text of project E:\PDA\Newton\Eigene
Software\NewtTest\DrawTest\NewtTest.NTK
written on: 02/10/03 02:05:54
// Beginning of file protoTimeSetter.lyt
TimeSetter :=
{viewBounds: {left: 22, top: 2, right: 200, bottom: 22},
viewFlags: 1,
viewFormat: 0,
viewJustify: 0,
debug: "TimeSetter",
viewClass: 74
};
MyCloseBox := /* child of TimeSetter */
{viewBounds: {left: -14, top: -13, bottom: 0, right: -1},
debug: "MyCloseBox",
_proto: @166
};
// View MyCloseBox is declared to TimeSetter
MyTextButton := /* child of TimeSetter */
{
buttonClickScript:
func()
begin
end,
text: "Button",
viewBounds: {left: -100, top: -16, bottom: -3, right: -30},
viewJustify: 8388774,
debug: "MyTextButton",
_proto: @226
};
// View MyTextButton is declared to TimeSetter
constant |layout_protoTimeSetter.lyt| := TimeSetter;
// End of file protoTimeSetter.lyt
// Beginning of file protoTestType.lyt
TestSubView :=
{viewFlags: 3,
viewFormat: 50397521,
viewJustify: 48,
debug: "TestSubView",
viewClass: 74
};
constant |layout_protoTestType.lyt| := TestSubView;
// End of file protoTestType.lyt
// Beginning of file NewtTest.lyt
NewtTest :=
{viewBounds: {left: 0, top: 0, right: 150, bottom: 150},
viewJustify: 80,
viewFormat: 83953137,
declareSelf:
'base // Needed for the close box
,
debug: "NewtTest",
_proto: @180
};
clViewUnderMainView := /* child of NewtTest */
{viewBounds: {left: 5, top: 0, bottom: 50, right: -5},
viewJustify: 112,
debug: "clViewUnderMainView",
_proto: TestSubView
};
// View clViewUnderMainView is declared to NewtTest
// Under OS1.3 and earlier clViewUnderClView is hidden. Button
// and checkbox work if you know where they are, their highlighed
// state is drawn if you tap them
clViewUnderClView := /* child of clViewUnderMainView */
{viewFormat: 201041,
viewJustify: 80,
viewBounds: {left: 0, top: 0, right: 105, bottom: 28},
debug: "clViewUnderClView",
_proto: TimeSetter
};
// View clViewUnderClView is declared to clViewUnderMainView
constant |layout_NewtTest.lyt| := NewtTest;
// End of file NewtTest.lyt
-- Newton Software and Hardware at http://www.pda-soft.de
-- This is the NewtonTalk list - http://www.newtontalk.net/ for all inquiries List FAQ/Etiquette/Terms: http://www.newtontalk.net/faq.html Official Newton FAQ: http://www.chuma.org/newton/faq/
This archive was generated by hypermail 2.1.5 : Sun Feb 09 2003 - 18:00:01 PST