Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: How to make Crimson match local macro delimiters in Stata


From   "Gabi Huiber" <ghuiber@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: How to make Crimson match local macro delimiters in Stata
Date   Tue, 19 Aug 2008 11:40:42 -0400

Hello everybody,

Those of you who have integrated Crimson with Stata (possibly
following Mr. Huebler's excellent instructions here:
http://huebler.blogspot.com/2008/04/stata.html) may have already done
this:

Crimson's Stata specification file (stata.spc) goes like this:

# STATA LANGUAGE SPECIFICATION FILE FOR CRIMSON EDITOR
# Stata 8
# Created By Jean Ries
# ries@ires.ucl.ac.be
# 03Sep2004

$CASESENSITIVE=YES
$DELIMITERS=~`!@#$%^&*()-+=|\{}[]:;",.<>/?
$VARIABLEPREFIX=$
$QUOTATIONMARK1="
$LINECOMMENT=//
$LINECOMMENTONFIRSTPOSITION=*
$BLOCKCOMMENTON=/*
$BLOCKCOMMENTOFF=*/
$PAIRS1=()
$PAIRS2=[]
$PAIRS3={}

I thought it would be nice if in addition to the parentheses, brackets
and braces Crimson also matched the (left single quote - apostrophe)
pair. So I thought that a stata.spc file that looked like this might
do it:

$CASESENSITIVE=YES
#$DELIMITERS=~`!@#$%^&*()-+=|\{}[]:;",.<>/?
#$VARIABLEPREFIX=$
$DELIMITERS=~`'!@#$%^&*()-+=|\{}[]:;",.<>/?
$VARIABLEPREFIX=`$
$QUOTATIONMARK1="
$LINECOMMENT=//
$LINECOMMENTONFIRSTPOSITION=*
$BLOCKCOMMENTON=/*
$BLOCKCOMMENTOFF=*/
$PAIRS1=()
$PAIRS2=[]
$PAIRS3={}
$PAIRS4=`'

You have to declare the elements in $PAIRS as delimiters beforehand,
and the apostrophe was not on the original list. Then I thought I'd
add ` to the $VARIABLEPREFIX too.

But none of that mattered. My stata.spc file won't match `'. Any ideas
why that might be?

Thank you,

Gabi
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index