Miscellaneous Techniques for Programming by Voice - PowerPoint PPT Presentation

1 / 20
About This Presentation
Title:

Miscellaneous Techniques for Programming by Voice

Description:

Navigate by line number. Kudos to Jonathan Epstein ... But, cursor may move by more than one line or character at a time. Continuous scrolling: Example ... – PowerPoint PPT presentation

Number of Views:31
Avg rating:3.0/5.0
Slides: 21
Provided by: ramirol
Category:

less

Transcript and Presenter's Notes

Title: Miscellaneous Techniques for Programming by Voice


1
Miscellaneous Techniques for Programming by Voice
  • Alain Désilets
  • Institute for Information Technology
  • National Research Council of Canada
  • Canada
  • alain.desilets _at_iit.nrc.ca

2
Miscellaneous techniques
  • Techniques discussed
  • Breadcrumbs
  • Navigation by line number
  • Continuous scrolling

3
Breadcrumbs
  • Similar to Back/Forward buttons in a browser
  • Certain commands automatically drop breadcrumbs
  • Can use commands to move forward/backward through
    the trail of breadcrumbs

4
Breadcrumbs Example
For ( )
Test.cpp
breadcrumb inserted here
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
search forward for get cited by
5
Breadcrumbs Example
For ( )
For ( )
Test.cpp
other crumb here
DocList DocumentgetCitedBy(mode
aMode) char temp256 fstream blank
hotList if( children NULL ) // call get
URL if( !getDocumentsCitedBy(hotList,
identifier) ) cout ltlt "CITEDBY " ltlt
identifier ltlt
" (primitive error)"
find again
6
Breadcrumbs Example
For ( )
For ( )
Test.cpp
aDocument (biblioDocList)biblioIndex mapUsing
(biblioIndex, aDocument-gtgetCitedBy(STORE))

back 2 crumbs
7
Breadcrumbs Example
For ( )
For ( )
Test.cpp
Popped back to original position
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
next crumb
8
Breadcrumbs Example
For ( )
For ( )
Test.cpp
Moved forward again
DocList DocumentgetCitedBy(mode
aMode) char temp256 fstream blank
hotList if( children NULL ) // call get
URL if( !getDocumentsCitedBy(hotList,
identifier) ) cout ltlt "CITEDBY " ltlt
identifier ltlt
" (primitive error)"
9
Navigate by line number
  • Kudos to Jonathan Epstein
  • Identify a target position by giving a line
    number and a particular landmark on that line
  • Landmark can be
  • punctuation mark
  • symbol
  • character
  • etc...

10
Navigate by line number Example
For ( )
Test.cpp
132 DocList DocumentgetCitedBy(mode
aMode) 133 134 char temp256 135 fstream
blank hotList 136 if ( children NULL
) 137 138 // call get URL 139 if(
!getDocumentsCitedBy(hotList, identifier) )
140 140 141 142 cout ltlt "CITEDBY " ltlt
identifier ltlt 143
" (primitive error)"
go to paren on 36
11
Navigate by line number Example
For ( )
Test.cpp
breadcrumb here
132 DocList DocumentgetCitedBy(mode
aMode) 133 134 char temp256 135 fstream
blank hotList 136 if ( children NULL
) 137 138 // call get URL 139 if(
!getDocumentsCitedBy(hotList, identifier) )
140 140 141 142 cout ltlt "CITEDBY " ltlt
identifier ltlt 143
" (primitive error)"
move cursor here
12
Continuous scrolling
  • Kudos to Jonathan Epstein
  • Similar to Dragon Move left/right/up/down macro
  • Tell cursor to move in a certain way
  • Cursor keeps scrolling until you ask it to stop
  • Can change direction and/or speed of movement
  • But, cursor may move by more than one line or
    character at a time

13
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
keep searching for a vector
14
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
move here...
15
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docIn
dex) if( left ! NULL ) aVectorleft-gtlistI
ndexesInOrder() retVector-gtadd(aVector)
here 1 sec later ...
16
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docIn
dex) if( left ! NULL ) aVectorleft-gtlistI
ndexesInOrder() retVector-gtadd(aVector)
here 1 sec later ...
faster
17
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
here 1/2 sec later ...
stop
18
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
after a some time
back
19
Continuous scrolling Example
For ( )
Test.cpp
Vector aVector Vector retVector new
Vector() if( right ! NULL ) aVector
right-gtlistIndexesInOrder() retVector-gtadd(aVec
tor) delete aVector retVector-gtadd(docInd
ex) if( left ! NULL ) aVectorleft-gtlistIn
dexesInOrder() retVector-gtadd(aVector)
here 1/2 sec later etc...
20
Continuous scrolling
  • Similar functionalities for
  • paging up/down
  • moving up/down one block of code at a time
  • moving up/down one function/class at a time
  • looping through open files
  • etc...
Write a Comment
User Comments (0)
About PowerShow.com