▼ |  | Dr Racket Plugins

1 | Implementing Dr Racket Plugins
2 | Adding Languages to Dr Racket
3 | Creating New Kinds of Dr Racket Frames
4 | Extending the Existing Dr Racket Classes
5 | Expanding the User’s Program Text and Breaking
6 | Editor Modes
7 | Language-Specific Capabilities
8 | Check Syntax
9 | Cooperating with Background Check Syntax
10 | Teaching Languages
11 | Signatures
12 | drracket: get/ extend
13 | drracket: unit
14 | drracket: language
15 | drracket: language-configuration
16 | drracket: debug
17 | drracket: rep
18 | drracket: frame
19 | drracket: help-desk
20 | drracket: eval
21 | drracket: modes
22 | drracket: module-language-tools
23 | drracket: module-language
24 | drracket: tracing
25 | Backwards Compatibility
| Index

On this page:

drracket: module-language: module-language<%>
get-users-language-name
drracket: module-language-tools: definitions-text<%>
move-to-new-language
get-in-module-language?
drracket: module-language-tools: tab<%>
drracket: module-language-tools: frame<%>
drracket: module-language-tools: definitions-text-mixin
drracket: module-language-tools: frame-mixin
drracket: module-language-tools: tab-mixin
drracket: module-language: add-module-language
drracket: module-language: module-language-put-file-mixin

top ← prev up next →

### 23`` drracket:module-language

interface drracket:module-language:module-language<%> : interface?

The only language that implements this interface is DrRacket’s “Use the language declared in the source” language.

> > method (send a-drracket:module-language:module-language get-users-language-name)
> > → string

> Returns the name of the language that is declared in the source, as a string.

interface drracket:module-language-tools:definitions-text<%> : interface?

> > method (send a-drracket:module-language-tools:definitions-text move-to-new-language)
> > → void?

> This method is called when a new language is evident in the definitions window (by editing the #lang line.

> > method (send a-drracket:module-language-tools:definitions-text get-in-module-language?)
> > → boolean?

> Returns #t when the current language setting (from the language dialog) is “The Racket Language”.

interface drracket:module-language-tools:tab<%> : interface?

This interface signals an implementation of a tab that specially handles programs beginning with #lang.

interface drracket:module-language-tools:frame<%> : interface?

This interface signals an implementation of a frame that specially handles programs beginning with #lang.

mixin drracket:module-language-tools:definitions-text-mixin : (class? . -> . class?)
argument extends/implements: | text:basic<%>
| racket:text<%>
| drracket:unit:definitions-text<%>
result implements: | drracket:module-language-tools:definitions-text<%>

mixin drracket:module-language-tools:frame-mixin : (class? . -> . class?)
argument extends/implements: | drracket:unit:frame<%>
result implements: | drracket:module-language-tools:frame<%>

mixin drracket:module-language-tools:tab-mixin : (class? . -> . class?)
argument extends/implements: | drracket:unit:tab<%>
result implements: | drracket:module-language-tools:tab<%>

> procedure (drracket:module-language:add-module-language) → any

Adds the module language to DrRacket. This is called during DrRacket’s startup.

> procedure (drracket:module-language:module-language-put-file-mixin super%)
> → (implementation?/c text:basic<%>)
> super% : (implementation?/c text:basic<%>)

Extends super% by overriding the put-file method to use a default name from the buffer, if the buffer contains something like (module name ...).
top ← prev up next →