##// END OF EJS Templates
add VERSIONHACK markers for never-released plaintext handling
MinRK -
Show More
@@ -1197,7 +1197,8 b' var IPython = (function (IPython) {'
1197 var new_cell = null;
1197 var new_cell = null;
1198 for (i=0; i<ncells; i++) {
1198 for (i=0; i<ncells; i++) {
1199 cell_data = new_cells[i];
1199 cell_data = new_cells[i];
1200 // handle short-lived plaintext name for raw cells
1200 // VERSIONHACK: plaintext -> raw
1201 // handle never-released plaintext name for raw cells
1201 if (cell_data.cell_type === 'plaintext'){
1202 if (cell_data.cell_type === 'plaintext'){
1202 cell_data.cell_type = 'raw';
1203 cell_data.cell_type = 'raw';
1203 }
1204 }
@@ -114,7 +114,8 b' def new_code_cell(input=None, prompt_number=None, outputs=None,'
114 def new_text_cell(cell_type, source=None, rendered=None):
114 def new_text_cell(cell_type, source=None, rendered=None):
115 """Create a new text cell."""
115 """Create a new text cell."""
116 cell = NotebookNode()
116 cell = NotebookNode()
117 # handle short-lived plaintext name for raw cells
117 # VERSIONHACK: plaintext -> raw
118 # handle never-released plaintext name for raw cells
118 if cell_type == 'plaintext':
119 if cell_type == 'plaintext':
119 cell_type = 'raw'
120 cell_type = 'raw'
120 if source is not None:
121 if source is not None:
@@ -68,6 +68,7 b' class PyReader(NotebookReader):'
68 state = u'markdowncell'
68 state = u'markdowncell'
69 cell_lines = []
69 cell_lines = []
70 kwargs = {}
70 kwargs = {}
71 # VERSIONHACK: plaintext -> raw
71 elif line.startswith(u'# <rawcell>') or line.startswith(u'# <plaintextcell>'):
72 elif line.startswith(u'# <rawcell>') or line.startswith(u'# <plaintextcell>'):
72 cell = self.new_cell(state, cell_lines, **kwargs)
73 cell = self.new_cell(state, cell_lines, **kwargs)
73 if cell is not None:
74 if cell is not None:
General Comments 0
You need to be logged in to leave comments. Login now