472,804 Members | 787 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,804 software developers and data experts.

mmm-mode, python-mode and doctest-mode?

Is it possible to get doctest-mode to work with mmm-mode and python-mode
nicely so that docstrings containing doctests are editable in
doctest-mode?

In my utter e-lisp ignorance, I tried this:

(require 'mmm-auto)
(setq mmm-global-mode 'maybe)
(mmm-add-classes
'(
(doctest
:submode doctest-mode
:front "\"\"\""
:back "\"\"\"")))
(mmm-add-mode-ext-class nil "\\.py$" 'doctest)

That has the following problems:

- Fails to set the background colour of the doctest-mode regions to the
default mmm-mode gray (as documented by mmm-mode - and observed for
another mmm class I have). Maybe an interaction with python-mode?

- Confuses python-mode: the face of docstrings sometimes fluctuates from
second to second between the string face and the face of ordinary text
(I assume the former face is python-mode's string face and the latter face
is the doctest-mode English-text face)!
Any tips appreciated!
John
Nov 30 '05 #1
3 2117
John J Lee wrote:
Is it possible to get doctest-mode to work with mmm-mode and python-mode
nicely so that docstrings containing doctests are editable in doctest-mode?
I don't know.

(snip)
Any tips appreciated!


Seems like comp.emacs could be a good place for this question....

--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom.gro'.split('@')])"
Dec 1 '05 #2
bruno at modulix <on***@xiludom.gro> writes:
John J Lee wrote:
Is it possible to get doctest-mode to work with mmm-mode and python-mode
nicely so that docstrings containing doctests are editable in doctest-mode?


I don't know.

(snip)

Any tips appreciated!


Seems like comp.emacs could be a good place for this question....


I've only posted to gnu.emacs.help previously (the message you reply
to was cross-posted there), since the name seemed to suggest
friendliness to people like me who use emacs a lot but are clueless
with elisp :-). But thinking again I guess comp.emacs is just the
general emacs group, while gnu.emacs.help is the GNU-specific one?
John

Dec 1 '05 #3
John J. Lee wrote:
bruno at modulix <on***@xiludom.gro> writes:

John J Lee wrote:
Is it possible to get doctest-mode to work with mmm-mode and python-mode
nicely so that docstrings containing doctests are editable in doctest-mode? (snip)
Seems like comp.emacs could be a good place for this question....

I've only posted to gnu.emacs.help previously (the message you reply
to was cross-posted there),


Sorry, did not see that. But then you should have set the follow-up there.
since the name seemed to suggest
friendliness to people like me who use emacs a lot but are clueless
with elisp :-)
You can script your emacs with Python too.
. But thinking again I guess comp.emacs is just the
general emacs group, while gnu.emacs.help is the GNU-specific one?


Probably. I must say I don't spend that much time configuring my
emacs... Changing mode manually when needed is ok for me.

--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'on***@xiludom.gro'.split('@')])"
Dec 1 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Ross Presser | last post by:
The purpose, as you can probably guess, is to produce a set of sample documents from a large document run. The data row has a CLUB column and an IFC column; I want a set of samples that contains...
4
by: yer darn tootin | last post by:
Does anyone know the sort expression for a column that's data has been returned in the format, eg '07 Jul 05'?? The sort expression {..:"dd mmm yy"} doesn't work ( if the column was returned as...
3
by: CyberLotus | last post by:
Hi, I wish to validate the date a user has entered against the format dd-mmm-yyyy using the CompareValidator, but it does not work. Does anybody have a simple solution please? Many thanks...
9
by: vinod.bhavnani | last post by:
Hello all, I have 2 qs about statements and their meanings in the C language. first If i have an array named int a and if i use a staement like
1
by: pavan | last post by:
please help me as i have to validate a text box for date....
2
by: Icarus27 | last post by:
Hello, I am making a program that runs off of a two dimentional array but I have made it into a game called MouseBot. I am trying to make the game so that you can move the mouse until you get the...
2
by: martinadhie | last post by:
Hi Guys, This is regular expression for validating dd-MMM-yyyy date format: ^(0|||3)-(|||||||||||)-(19|20)\d\d$ It will not allow case like 0-Aug-2007, should be 01-Aug-2007 Thanks,...
3
by: neoupadhyay | last post by:
Hi Friends, I am Using ASP.NET1.1 and i want to convert the system date, in dd/MMM/yyyy format. Earlier i use lblDate.Text = System.DateTime.Now.AddMinutes(30).ToString(); But i want to...
4
by: bae14 | last post by:
I have a file I'm trying to import into Access that has dates in it that are in the form MMM-YY (JAN-07) and Access isn't letting me import it in as a date. It says type conversion error. I need this...
11
ollyb303
by: ollyb303 | last post by:
Hello, I am using a dynamic crosstab report to track performance statistics for my company and I have hit a problem. I would like the option to track stats daily (for the last 7 complete...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
linyimin
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
0
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
14
DJRhino1175
by: DJRhino1175 | last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this - If...
0
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
0
by: lllomh | last post by:
How does React native implement an English player?
0
by: Mushico | last post by:
How to calculate date of retirement from date of birth
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.