[Date Index]
[Thread Index]
[Author Index]
Re: [TS 1012]--Re:Re: [TS 503]--Re:OverVector Context
*To*: mathgroup at smc.vnet.net
*Subject*: [mg72931] Re: [TS 1012]--Re:Re: [TS 503]--Re:OverVector Context
*From*: "Chris Chiasson" <chris at chiasson.name>
*Date*: Thu, 25 Jan 2007 07:39:35 -0500 (EST)
*References*: <200701242130.l0OLU1en009002@localhost.localdomain>
I don't know if I could say it better than the original person that
wrote the suggestion, but:
Formatting on local names is seemingly inconsistent with the
architecture of the rest of Mathematica. These are definitions that
are allowed to affect symbols in any context.
On the other hand, I can't come up with any situation where I think
these rules might break because it would be a fool's errand to define
formatting (and other) rules for, say, MyContext`OverVector and then
expect that to not conflict with the assumed definition of
System`OverVector. However, I think the definition of rules on local
names is the beginning of a dangerous trend that should not continue.
On Wed, 24 Jan 2007 21:30:01 UT, support at wolfram.com
<support at wolfram.com> wrote:
> -- Wolfram Research Technical Support --
>
> This is a response to your email.
> The reply to your question can be found at the bottom of this message.
> Our classification number for this message is: [TS 1012]
> Please give this number in any future correspondence
> related to this question. If you leave this number in
> the Subject: header in the form [TS 1012], it will
> automatically be reassigned to the original technician.
>
> From: "Chris Chiasson" <chris at chiasson.name>
> Date: Fri, 12 Jan 2007 10:47:55 -0600
> Subject: Re: [TS 503]--Re:OverVector Context
> To: "support at wolfram.com" <support at wolfram.com>,mathgroup <mathgroup at smc.vnet.net>
>
> Tom,
>
> You'll see the difference if you put something like Subscript in place
> of OverVector. Subscript is in the "System`" context. OverVector
> doesn't have a context defined, but somehow still has formatting rules
> (meaning Mathematica is looking at only the local name of the symbol
> to do the formatting in the case of OverVector).
>
> BeginPackage@"Heh`";
> Begin@"`Private`";
> OverVector@b;
> Context@OverVector
>
> On Fri, 12 Jan 2007 14:00:00 UT, support at wolfram.com
> <support at wolfram.com> wrote:
> > -- Wolfram Research Technical Support --
> >
> > This is a response to your email.
> > The reply to your question can be found at the bottom of this message.
> > Our classification number for this message is: [TS 503]
> > Please give this number in any future correspondence
> > related to this question. If you leave this number in
> > the Subject: header in the form [TS 503], it will
> > automatically be reassigned to the original technician.
> >
> > From: "Chris Chiasson" <chris at chiasson.name>
> > Date: Sun, 7 Jan 2007 07:26:42 -0600
> > Subject: OverVector Context
> > To: "support at wolfram.com" <support at wolfram.com>,mathgroup <mathgroup at smc.vnet.net>
> >
> > OverVector doesn't have a context at the beginning of a session
> >
> > BeginPackage@"Heh`";
> > Begin@"`Private`";
> > OverVector@b;
> > Context@OverVector
> >
> > gives
> >
> > "Heh`Private`"
> >
> > I guess this is somewhat useful because it allows package authors to
> > give DownValues values to OverVector@arg without worrying about the
> > effect in another package. However, I am wondering why the Context is
> > any different from, say, Subscript?
> >
> > It just seems weird to have default formatting rules for symbols (like
> > OverBar and OverVector) with certain local names but any Context name.
> >
> > --
> > http://chris.chiasson.name/
> >
> > _______________________________________________________________________
> > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >
> > Chris,
> >
> > Unless I am missing something, I think how and why of this is covered in
> > the Documentation for BeginPackage. There is also an FAQ at:
> >
> > http://support.wolfram.com/mathematica/packages/writing/context.html
> >
> > and other package writing FAQs at:
> >
> > http://support.wolfram.com/mathematica/packages/writing/
> >
> > If there are examples that don't fit the described behavior, please
> > send them in.
> >
> > Tom Zeller
> > Wolfram Research Technical Support
> >
> >
> >
> >
> >
> > ----------------------------------------------------------------------------
> >
> > If this issue is resolved, please consider taking a few minutes
> > to give us some feedback on your experience. Please visit
> > http://support.wolfram.com/survey/?trackingnumber=503
> > and give your honest answers to these three short questions.
> > Thanks for taking the time to help us improve.
> >
>
>
> ________________________________________________________________________
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Chris,
>
> Of the 16 symbols in the last "definitions" box in section 2.9.15
> of the Mathematica Book, only 3 are in the System` Context -
> {Subscript, Overscript, Underscript}. All of the others begin their
> "lives" with no Context as you noticed with OverVector and then take
> on whatever Context in which they are first used in the Kernel session.
> As far as I can tell the formating is something "known" by the FrontEnd,
> even if the symbols are not "known" by the kernel until they are used.
> This might be seen as akin to the font and other formatting that the
> FrontEnd does to Input or Output.
>
> There is an open Suggestion to the developers (from a while back) that
> these Symbols be put into the System` context. If you have arguments to
> make as to why this should be done, I can add them to that Suggestion text.
>
> Tom Zeller
> Wolfram Research Technical Support
>
>
> ----------------------------------------------------------------------------
>
> If this issue is resolved, please consider taking a few minutes
> to give us some feedback on your experience. Please visit
> http://support.wolfram.com/survey/?trackingnumber=1012
> and give your honest answers to these three short questions.
> Thanks for taking the time to help us improve.
>
--
http://chris.chiasson.name/
Prev by Date:
**Re: Option for continuous plot**
Next by Date:
**Re: pdf**
Previous by thread:
**when draw the piechart,how to write the label outside the piechart**
Next by thread:
**can't InstallJava[] on Linux-x86-64 to Import an xls file**
| |