Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Matthew Flatt
And maybe helpful for the original question: Including `(alt-tag
"div")` in the property list of your styles produces  in the HTML
output instead of , which is more directly what you want
and avoids any default inset of .

At Thu, 21 May 2015 16:52:12 -0400, Shriram Krishnamurthi wrote:
> Of course it is. I can certainly hack my way around it using CSS. But
> I'm wondering why the behavior doesn't match my reading of the docs:
> did I misread, is the code broken, or are the docs broken? That's
> really all I'm trying to figure out. (And if the code or docs are
> wrong, then presumably someone who maintains them would like a bug
> report.)
> 
> Shriram
> 
> On Thu, May 21, 2015 at 4:21 PM, Matthias Felleisen
>  wrote:
> >
> > Isn't it the whole point of styles to allow this kind of fixes? I am 
> > playing 
> with similar fixes for TeX output. Scribble is an UNCOL and all UNCOLs fail a 
> little bit at least -- Matthias
> >
> >
> >
> >
> > On May 21, 2015, at 2:19 PM, Shriram Krishnamurthi  
> > wrote:
> >
> >> Understood. But my understanding of the docs is that it shouldn't do
> >> that in the first place.
> >>
> >> On Thu, May 21, 2015 at 2:15 PM, Ben Lerner  wrote:
> >>> Probably a CSS fix: assuming you have something like this in your CSS
> >>> preamble
> >>>
> >>> div.question { padding-left: 2em; }
> >>>
> >>> to cause the indentation, then something like this will disable the nested
> >>> one:
> >>>
> >>> div.exercise > div.question { padding-left: 0em; }
> >>>
> >>> ~ben
> >>>
> >>> On 5/21/2015 2:12 PM, Shriram Krishnamurthi wrote:
> >>>
> >>> Thanks for these replies. Sorry I'm only now getting to them: Google 
> >>> failed
> >>> to notify me of them.
> >>>
> >>> The problem with using (nested ...) is that it indents its content even 
> >>> when
> >>> I don't use the 'inset style. Therefore, if I have (as I do)
> >>>
> >>> @exercise{@question{...}}
> >>>
> >>> everything in the exercise ends up nested one level, and the question ends
> >>> up nested two levels. That's why I rejected the use of `nested` and was
> >>> looking for alternate solutions.
> >>>
> >>> How can I get `nested` to not indent? I have exactly what you suggested:
> >>>
> >>> (define (exercise . t) (nested #:style question-style t))
> >>> (define (question . t)  (nested #:style question-style t))
> >>>
> >>> where
> >>>
> >>> (define exercise-style (make-style "exercise" null))
> >>> (define question-style (make-style "question" null))
> >>>
> >>> and this still leads to the indentation.
> >>>
> >>
> >> --
> >> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> >> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> >> For more options, visit https://groups.google.com/d/optout.
> >
> > --
> > You received this message because you are subscribed to a topic in the 
> > Google 
> Groups "Racket Users" group.
> > To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/racket-users/ZJqovwguPGQ/unsubscribe.
> > To unsubscribe from this group and all its topics, send an email to 
> racket-users+unsubscr...@googlegroups.com.
> > For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email 
> to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Matthew Flatt
I'll revise the docs to clarify that the default style is up to the
target environment. For HTML output, `nested` corresponds to
, and that (usually?) insets its content by default. For
Latex output, `nested` corresponds to a plain list environment, which
doesn't inset.

At Thu, 21 May 2015 16:52:12 -0400, Shriram Krishnamurthi wrote:
> Of course it is. I can certainly hack my way around it using CSS. But
> I'm wondering why the behavior doesn't match my reading of the docs:
> did I misread, is the code broken, or are the docs broken? That's
> really all I'm trying to figure out. (And if the code or docs are
> wrong, then presumably someone who maintains them would like a bug
> report.)
> 
> Shriram
> 
> On Thu, May 21, 2015 at 4:21 PM, Matthias Felleisen
>  wrote:
> >
> > Isn't it the whole point of styles to allow this kind of fixes? I am 
> > playing 
> with similar fixes for TeX output. Scribble is an UNCOL and all UNCOLs fail a 
> little bit at least -- Matthias
> >
> >
> >
> >
> > On May 21, 2015, at 2:19 PM, Shriram Krishnamurthi  
> > wrote:
> >
> >> Understood. But my understanding of the docs is that it shouldn't do
> >> that in the first place.
> >>
> >> On Thu, May 21, 2015 at 2:15 PM, Ben Lerner  wrote:
> >>> Probably a CSS fix: assuming you have something like this in your CSS
> >>> preamble
> >>>
> >>> div.question { padding-left: 2em; }
> >>>
> >>> to cause the indentation, then something like this will disable the nested
> >>> one:
> >>>
> >>> div.exercise > div.question { padding-left: 0em; }
> >>>
> >>> ~ben
> >>>
> >>> On 5/21/2015 2:12 PM, Shriram Krishnamurthi wrote:
> >>>
> >>> Thanks for these replies. Sorry I'm only now getting to them: Google 
> >>> failed
> >>> to notify me of them.
> >>>
> >>> The problem with using (nested ...) is that it indents its content even 
> >>> when
> >>> I don't use the 'inset style. Therefore, if I have (as I do)
> >>>
> >>> @exercise{@question{...}}
> >>>
> >>> everything in the exercise ends up nested one level, and the question ends
> >>> up nested two levels. That's why I rejected the use of `nested` and was
> >>> looking for alternate solutions.
> >>>
> >>> How can I get `nested` to not indent? I have exactly what you suggested:
> >>>
> >>> (define (exercise . t) (nested #:style question-style t))
> >>> (define (question . t)  (nested #:style question-style t))
> >>>
> >>> where
> >>>
> >>> (define exercise-style (make-style "exercise" null))
> >>> (define question-style (make-style "question" null))
> >>>
> >>> and this still leads to the indentation.
> >>>
> >>
> >> --
> >> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> >> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> >> For more options, visit https://groups.google.com/d/optout.
> >
> > --
> > You received this message because you are subscribed to a topic in the 
> > Google 
> Groups "Racket Users" group.
> > To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/racket-users/ZJqovwguPGQ/unsubscribe.
> > To unsubscribe from this group and all its topics, send an email to 
> racket-users+unsubscr...@googlegroups.com.
> > For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email 
> to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Shriram Krishnamurthi
Of course it is. I can certainly hack my way around it using CSS. But
I'm wondering why the behavior doesn't match my reading of the docs:
did I misread, is the code broken, or are the docs broken? That's
really all I'm trying to figure out. (And if the code or docs are
wrong, then presumably someone who maintains them would like a bug
report.)

Shriram

On Thu, May 21, 2015 at 4:21 PM, Matthias Felleisen
 wrote:
>
> Isn't it the whole point of styles to allow this kind of fixes? I am playing 
> with similar fixes for TeX output. Scribble is an UNCOL and all UNCOLs fail a 
> little bit at least -- Matthias
>
>
>
>
> On May 21, 2015, at 2:19 PM, Shriram Krishnamurthi  wrote:
>
>> Understood. But my understanding of the docs is that it shouldn't do
>> that in the first place.
>>
>> On Thu, May 21, 2015 at 2:15 PM, Ben Lerner  wrote:
>>> Probably a CSS fix: assuming you have something like this in your CSS
>>> preamble
>>>
>>> div.question { padding-left: 2em; }
>>>
>>> to cause the indentation, then something like this will disable the nested
>>> one:
>>>
>>> div.exercise > div.question { padding-left: 0em; }
>>>
>>> ~ben
>>>
>>> On 5/21/2015 2:12 PM, Shriram Krishnamurthi wrote:
>>>
>>> Thanks for these replies. Sorry I'm only now getting to them: Google failed
>>> to notify me of them.
>>>
>>> The problem with using (nested ...) is that it indents its content even when
>>> I don't use the 'inset style. Therefore, if I have (as I do)
>>>
>>> @exercise{@question{...}}
>>>
>>> everything in the exercise ends up nested one level, and the question ends
>>> up nested two levels. That's why I rejected the use of `nested` and was
>>> looking for alternate solutions.
>>>
>>> How can I get `nested` to not indent? I have exactly what you suggested:
>>>
>>> (define (exercise . t) (nested #:style question-style t))
>>> (define (question . t)  (nested #:style question-style t))
>>>
>>> where
>>>
>>> (define exercise-style (make-style "exercise" null))
>>> (define question-style (make-style "question" null))
>>>
>>> and this still leads to the indentation.
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups 
>> "Racket Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to racket-users+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to a topic in the Google 
> Groups "Racket Users" group.
> To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/racket-users/ZJqovwguPGQ/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to 
> racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Alexander D. Knauth
I don’t know if there’s a better more general solution, but does this do what 
you want?
@(define exercise-style (make-style "exercise" (list (attributes '([style . 
"margin-left: 0em"])
@(define question-style (make-style "question" (list (attributes '([style . 
"margin-left: 0em"])
@(define answer-style (make-style "answer" (list (attributes '([style . 
"margin-left: 0em"])

On May 21, 2015, at 2:12 PM, Shriram Krishnamurthi  wrote:

> Thanks for these replies. Sorry I'm only now getting to them: Google failed 
> to notify me of them.
> 
> The problem with using (nested ...) is that it indents its content even when 
> I don't use the 'inset style. Therefore, if I have (as I do)
> 
> @exercise{@question{...}}
> 
> everything in the exercise ends up nested one level, and the question ends up 
> nested two levels. That's why I rejected the use of `nested` and was looking 
> for alternate solutions.
> 
> How can I get `nested` to not indent? I have exactly what you suggested:
> 
> (define (exercise . t) (nested #:style question-style t))
> (define (question . t)  (nested #:style question-style t))
> 
> where
> 
> (define exercise-style (make-style "exercise" null))
> (define question-style (make-style "question" null))
> 
> and this still leads to the indentation.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Matthias Felleisen

Isn't it the whole point of styles to allow this kind of fixes? I am playing 
with similar fixes for TeX output. Scribble is an UNCOL and all UNCOLs fail a 
little bit at least -- Matthias




On May 21, 2015, at 2:19 PM, Shriram Krishnamurthi  wrote:

> Understood. But my understanding of the docs is that it shouldn't do
> that in the first place.
> 
> On Thu, May 21, 2015 at 2:15 PM, Ben Lerner  wrote:
>> Probably a CSS fix: assuming you have something like this in your CSS
>> preamble
>> 
>> div.question { padding-left: 2em; }
>> 
>> to cause the indentation, then something like this will disable the nested
>> one:
>> 
>> div.exercise > div.question { padding-left: 0em; }
>> 
>> ~ben
>> 
>> On 5/21/2015 2:12 PM, Shriram Krishnamurthi wrote:
>> 
>> Thanks for these replies. Sorry I'm only now getting to them: Google failed
>> to notify me of them.
>> 
>> The problem with using (nested ...) is that it indents its content even when
>> I don't use the 'inset style. Therefore, if I have (as I do)
>> 
>> @exercise{@question{...}}
>> 
>> everything in the exercise ends up nested one level, and the question ends
>> up nested two levels. That's why I rejected the use of `nested` and was
>> looking for alternate solutions.
>> 
>> How can I get `nested` to not indent? I have exactly what you suggested:
>> 
>> (define (exercise . t) (nested #:style question-style t))
>> (define (question . t)  (nested #:style question-style t))
>> 
>> where
>> 
>> (define exercise-style (make-style "exercise" null))
>> (define question-style (make-style "question" null))
>> 
>> and this still leads to the indentation.
>> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Shriram Krishnamurthi
Understood. But my understanding of the docs is that it shouldn't do
that in the first place.

On Thu, May 21, 2015 at 2:15 PM, Ben Lerner  wrote:
> Probably a CSS fix: assuming you have something like this in your CSS
> preamble
>
> div.question { padding-left: 2em; }
>
> to cause the indentation, then something like this will disable the nested
> one:
>
> div.exercise > div.question { padding-left: 0em; }
>
> ~ben
>
> On 5/21/2015 2:12 PM, Shriram Krishnamurthi wrote:
>
> Thanks for these replies. Sorry I'm only now getting to them: Google failed
> to notify me of them.
>
> The problem with using (nested ...) is that it indents its content even when
> I don't use the 'inset style. Therefore, if I have (as I do)
>
> @exercise{@question{...}}
>
> everything in the exercise ends up nested one level, and the question ends
> up nested two levels. That's why I rejected the use of `nested` and was
> looking for alternate solutions.
>
> How can I get `nested` to not indent? I have exactly what you suggested:
>
> (define (exercise . t) (nested #:style question-style t))
> (define (question . t)  (nested #:style question-style t))
>
> where
>
> (define exercise-style (make-style "exercise" null))
> (define question-style (make-style "question" null))
>
> and this still leads to the indentation.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Ben Lerner

  
  

  Probably a CSS fix:
assuming you have something like this in your CSS preamble
  div.question { padding-left: 2em; }

  to cause the
indentation, then something like this will disable the nested
one:
  div.exercise > div.question { padding-left: 0em; }

  ~ben
  On 5/21/2015 2:12 PM,
Shriram Krishnamurthi wrote:
  
  


  Thanks for these replies. Sorry I'm only now getting to them: Google failed to notify me of them.

The problem with using (nested ...) is that it indents its content even when I don't use the 'inset style. Therefore, if I have (as I do)

@exercise{@question{...}}

everything in the exercise ends up nested one level, and the question ends up nested two levels. That's why I rejected the use of `nested` and was looking for alternate solutions.

How can I get `nested` to not indent? I have exactly what you suggested:

(define (exercise . t) (nested #:style question-style t))
(define (question . t)  (nested #:style question-style t))

where

(define exercise-style (make-style "exercise" null))
(define question-style (make-style "question" null))

and this still leads to the indentation.




  
  
  ​

  




-- 
You received this message because you are subscribed to the Google Groups "Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-05-21 Thread Shriram Krishnamurthi
Thanks for these replies. Sorry I'm only now getting to them: Google failed to 
notify me of them.

The problem with using (nested ...) is that it indents its content even when I 
don't use the 'inset style. Therefore, if I have (as I do)

@exercise{@question{...}}

everything in the exercise ends up nested one level, and the question ends up 
nested two levels. That's why I rejected the use of `nested` and was looking 
for alternate solutions.

How can I get `nested` to not indent? I have exactly what you suggested:

(define (exercise . t) (nested #:style question-style t))
(define (question . t)  (nested #:style question-style t))

where

(define exercise-style (make-style "exercise" null))
(define question-style (make-style "question" null))

and this still leads to the indentation.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-04-22 Thread Alexander D. Knauth
I just tried (nested #:style question-style t) and that worked.  What got that 
to fail?
Also I should have tried elem with answer, not just question.

On Apr 22, 2015, at 5:21 PM, Alexander D. Knauth  wrote:

> Would something like
> (define (question . t) (apply elem #:style question-style . t))
> work?
> 
> On Apr 22, 2015, at 5:08 PM, Shriram Krishnamurthi  wrote:
> 
>> I'm having trouble with the type structure of Scribble and hoping someone 
>> can help me get this right.
>> 
>> Let's say I want to write content like this:
>> 
>> =
>> 
>> @exercise{
>> @question{The expression @code{1 + 2} evaluates to}
>> @answer{
>> @itemlist[
>> @item{@code{2}}
>> @item{@code{3}}
>> @item{@code{4}}
>> ]
>> }
>> }
>> 
>> =
>> 
>> That is, an `exercise` contains within it a `question` and an `answer` (and 
>> maybe other parts). Each of those can contain compound content (text, code, 
>> itemlists...). In my (HTML) output I would like each of these to have their 
>> own class tags, so the structure looks like
>> 
>> 
>>   ...
>>   
>> ...
>>   
>>   ...
>>   
>> ...
>>   
>>   ...
>> 
>> 
>> I have set up styles as follows:
>> 
>> (define exercise-style (make-style "exercise" null))
>> (define question-style (make-style "question" null))
>> (define answer-style (make-style "answer" null))
>> 
>> What I'm trying to do is create the correct form of "pass-through" 
>> abstraction for the `exercise`, `question`, and `answer` functions that just 
>> attach the style and leave everything else alone: e.g.,
>> 
>> (define (exercise . t) (nested-flow exercise-style t))
>> (define (question . t) (nested #:style question-style t))
>> 
>> I have tried a whole bunch of things (`nested`, `nested-flow`, etc.) and 
>> cannot get anything to work correctly, consistently: each thing I try 
>> eventually results in a contract violation such as
>> 
>> make-nested-flow: contract violation
>>   expected: block?
>>   given: "\n"
>> 
>> TIA,
>> Shriram
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Racket Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to racket-users+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Scribble abstraction to attach styles

2015-04-22 Thread Alexander D. Knauth
Would something like
(define (question . t) (apply elem #:style question-style . t))
work?

On Apr 22, 2015, at 5:08 PM, Shriram Krishnamurthi  wrote:

> I'm having trouble with the type structure of Scribble and hoping someone can 
> help me get this right.
> 
> Let's say I want to write content like this:
> 
> =
> 
> @exercise{
> @question{The expression @code{1 + 2} evaluates to}
> @answer{
> @itemlist[
> @item{@code{2}}
> @item{@code{3}}
> @item{@code{4}}
> ]
> }
> }
> 
> =
> 
> That is, an `exercise` contains within it a `question` and an `answer` (and 
> maybe other parts). Each of those can contain compound content (text, code, 
> itemlists...). In my (HTML) output I would like each of these to have their 
> own class tags, so the structure looks like
> 
>  
>...
>
>  ...
>
>...
>
>  ...
>
>...
>  
> 
> I have set up styles as follows:
> 
>  (define exercise-style (make-style "exercise" null))
>  (define question-style (make-style "question" null))
>  (define answer-style (make-style "answer" null))
> 
> What I'm trying to do is create the correct form of "pass-through" 
> abstraction for the `exercise`, `question`, and `answer` functions that just 
> attach the style and leave everything else alone: e.g.,
> 
>  (define (exercise . t) (nested-flow exercise-style t))
>  (define (question . t) (nested #:style question-style t))
> 
> I have tried a whole bunch of things (`nested`, `nested-flow`, etc.) and 
> cannot get anything to work correctly, consistently: each thing I try 
> eventually results in a contract violation such as
> 
>  make-nested-flow: contract violation
>expected: block?
>given: "\n"
> 
> TIA,
> Shriram
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[racket-users] Scribble abstraction to attach styles

2015-04-22 Thread Shriram Krishnamurthi
I'm having trouble with the type structure of Scribble and hoping someone can 
help me get this right.

Let's say I want to write content like this:

=

@exercise{
@question{The expression @code{1 + 2} evaluates to}
@answer{
@itemlist[
@item{@code{2}}
@item{@code{3}}
@item{@code{4}}
]
}
}

=

That is, an `exercise` contains within it a `question` and an `answer` (and 
maybe other parts). Each of those can contain compound content (text, code, 
itemlists...). In my (HTML) output I would like each of these to have their own 
class tags, so the structure looks like

  
...

  ...

...

  ...

...
  

I have set up styles as follows:

  (define exercise-style (make-style "exercise" null))
  (define question-style (make-style "question" null))
  (define answer-style (make-style "answer" null))

What I'm trying to do is create the correct form of "pass-through" abstraction 
for the `exercise`, `question`, and `answer` functions that just attach the 
style and leave everything else alone: e.g.,

  (define (exercise . t) (nested-flow exercise-style t))
  (define (question . t) (nested #:style question-style t))

I have tried a whole bunch of things (`nested`, `nested-flow`, etc.) and cannot 
get anything to work correctly, consistently: each thing I try eventually 
results in a contract violation such as

  make-nested-flow: contract violation
expected: block?
given: "\n"

TIA,
Shriram

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.