editor.jade 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. div.full-size(
  2. ng-show="ui.view == 'editor'"
  3. layout="pdf"
  4. layout-disabled="ui.pdfLayout != 'sideBySide'"
  5. mask-iframes-on-resize="true"
  6. resize-on="layout:main:resize"
  7. resize-proportionally="true"
  8. initial-size-east="'50%'"
  9. )
  10. .ui-layout-center
  11. .loading-panel(ng-show="!editor.sharejs_doc || editor.opening")
  12. i.fa.fa-spin.fa-refresh
  13. |   #{translate("loading")}...
  14. #editor(
  15. ace-editor="editor",
  16. ng-show="!!editor.sharejs_doc && !editor.opening"
  17. theme="settings.theme",
  18. keybindings="settings.mode",
  19. font-size="settings.fontSize",
  20. auto-complete="settings.autoComplete",
  21. spell-check-language="project.spellCheckLanguage",
  22. highlights="onlineUserCursorHighlights[editor.open_doc_id]"
  23. show-print-margin="false",
  24. sharejs-doc="editor.sharejs_doc",
  25. last-updated="editor.last_updated",
  26. cursor-position="editor.cursorPosition",
  27. goto-line="editor.gotoLine",
  28. resize-on="layout:main:resize,layout:pdf:resize",
  29. annotations="pdf.logEntryAnnotations[editor.open_doc_id]",
  30. read-only="!permissions.write",
  31. on-ctrl-enter="recompile"
  32. )
  33. .ui-layout-east
  34. div(ng-if="ui.pdfLayout == 'sideBySide'")
  35. include ./pdf
  36. .ui-layout-resizer-controls.synctex-controls(
  37. ng-show="!!pdf.url && settings.pdfViewer == 'pdfjs'"
  38. ng-controller="PdfSynctexController"
  39. )
  40. a.btn.btn-default.btn-xs(
  41. tooltip="#{translate('go_to_code_location_in_pdf')}"
  42. tooltip-placement="right"
  43. tooltip-append-to-body="true"
  44. ng-click="syncToPdf()"
  45. )
  46. i.fa.fa-long-arrow-right
  47. br
  48. a.btn.btn-default.btn-xs(
  49. tooltip-html-unsafe="#{translate('go_to_pdf_location_in_code')}"
  50. tooltip-placement="right"
  51. tooltip-append-to-body="true"
  52. ng-click="syncToCode()"
  53. )
  54. i.fa.fa-long-arrow-left
  55. div.full-size(
  56. ng-if="ui.pdfLayout == 'flat'"
  57. ng-show="ui.view == 'pdf'"
  58. )
  59. include ./pdf