Alice

 view release on metacpan or  search on metacpan

share/static/alice-dark.css  view on Meta::CPAN

  margin: 0;
  padding: 0;
  overflow: hidden;
  color: white;
  -webkit-text-size-adjust: none !important; }

img {
  border: none; }

ul#tabs li:hover {
  cursor: default; }

div#tab_bar .dropdown {
  opacity: 0;
  width: 24px;
  height: 24px;
  z-index: 905; }

div#join_button {
  position: absolute;
  bottom: 0px;
  right: 12px;
  width: 24px;
  height: 24px;
  background: url(image/sprites.png) -32px -36px no-repeat;
  cursor: pointer; }

div#join_button:hover {
  background: url(image/sprites.png) -32px -56px no-repeat; }

div#tab_bar div#tabset_dropdown {
  position: absolute;
  bottom: 0px;
  left: 0px;
  background: url(image/sprites.png) -29px 4px no-repeat;
  opacity: 1;
  cursor: pointer; }

div#tab_bar div#tabset_dropdown:hover {
  background: url(image/sprites.png) -29px -16px no-repeat; }

div#tab_bar .dropdown.active {
  opacity: 1;
  cursor: pointer; }

div#tab_menu_left {
  position: absolute;
  left: 24px;
  bottom: 0px;
  border-right: 1px solid #222222; }

div#tab_menu_left ul {
  left: 0px;
  right: auto; }

share/static/alice-dark.css  view on Meta::CPAN

  background: url(image/sprites.png) -29px -236px no-repeat; }

div#config_menu {
  top: 0px;
  left: 0px;
  height: 17px;
  border: #fff;
  border: 1px solid #999999;
  border-bottom: 1px solid #333333;
  border-right: 1px solid #333333;
  cursor: pointer;
  position: absolute;
  z-index: 902;
  background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAaCAYAAAADiYpyAAADG0lEQVRYw+2ZS0hVURSGr9qVBipGDysaZUIRRQ9u70FlgwYZFTRp0ItIgqKixEERBE2i6A1FWUjSKKGoBiVZEEnRw8oKa9KLoIcQZWqW5teg/8DicM6596gHruiBhey19tp7r+/svfY61xgQGxBiAxAiBpEJtLpkRn...
  background-color: #555555;
  background-size: 33px 13px;
  width: 50px; }

div#config_menu > ul {
  margin-left: -1px; }

@media screen and (-webkit-device-pixel-ratio: 2) {
  div#config_menu {
    top: 0px;
    left: 0px;
    height: 17px;
    border: #fff;
    border: 1px solid #999999;
    border-bottom: 1px solid #333333;
    border-right: 1px solid #333333;
    cursor: pointer;
    position: absolute;
    z-index: 902;
    background: url(image/logo2x.png) center center no-repeat;
    -webkit-background-size: 33px 13px;
    background-color: #555555;
    width: 53px; } }
div#config_menu ul ul {
  left: 100%;
  right: auto;
  margin-left: -2px; }

share/static/alice-dark.css  view on Meta::CPAN

  -webkit-transition-property: opacity, width;
  -webkit-transition-duration: 0.3s, 0.2s;
  -webkit-transition-timing-function: ease-in-out;
  -moz-transition-property: opacity, width;
  -moz-transition-duration: 0.3s, 0.2s;
  -moz-transition-timing-function: ease-in-out;
  border-radius: 2px;
  color: white;
  font-size: 14px;
  z-index: 902;
  cursor: pointer;
  opacity: 0; }

div#nicklist_toggle:hover {
  background-color: #3a3a3a; }

div#windows.nicklist div#nicklist_toggle {
  background-image: url(image/slider-right.png); }

div#nicklist_toggle.visible,
div#nicklist_toggle:hover,

share/static/alice-dark.css  view on Meta::CPAN

div#windows.nicklist ul#nicklist {
  right: 0px;
  left: auto;
  visibility: visible; }

ul#nicklist li {
  display: block;
  padding: 3px 5px 0px 5px; }

ul#nicklist li a {
  cursor: pointer;
  color: white;
  font-size: 0.8em; }

div#input {
  background: #333333;
  border-bottom: 1px solid #222222;
  border-top: 1px solid #444444;
  position: absolute;
  bottom: 24px;
  left: 0px;

share/static/alice-dark.css  view on Meta::CPAN

div#input div.editor_toolbar button {
  display: block;
  float: left;
  color: white;
  line-height: 12px;
  font-size: 12px;
  margin: 0;
  padding: 4px 4px;
  text-align: center;
  background: none;
  cursor: pointer;
  border: none;
  color: #666666; }

div#input div.editor_toolbar button.colors:hover {
  background: none; }

div#input div.editor_toolbar button.colors {
  width: 14px;
  height: 14px;
  border: 2px solid white;

share/static/alice-dark.css  view on Meta::CPAN

div.image a a.hideimg {
  position: absolute;
  white-space: nowrap;
  top: 0px;
  left: 0px;
  right: 0px;
  text-align: center;
  opacity: 0;
  color: #fff;
  padding: 4px 0px;
  cursor: pointer;
  font-size: 11px;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5); }

div.image a:hover a.hideimg {
  opacity: 1;
  background: rgba(0, 0, 0, 0.25); }

div.image a a.hideimg:hover {
  background: rgba(0, 0, 0, 0.5);
  opacity: 1; }

share/static/alice-dark.css  view on Meta::CPAN

  border-left: none; }

ul.messages li.event div.left {
  font-weight: normal; }

ul.messages li.announce div.msg {
  color: #777;
  white-space: pre-wrap; }

div.msg img.audio {
  cursor: pointer;
  display: inline;
  padding: 0 4px;
  width: 16px;
  height: 16px;
  margin-bottom: -3px; }

a.nick {
  color: white;
  text-decoration: none; }

share/static/alice-dark.css  view on Meta::CPAN

  position: absolute;
  top: 17px;
  right: 20px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 9px;
  letter-spacing: 1px;
  text-shadow: none;
  text-transform: uppercase; }

div#help div#helpclose:hover {
  cursor: pointer;
  color: #fff; }

div#help div#topics {
  position: absolute;
  top: 34px;
  bottom: 15px;
  left: 20px;
  right: 20px;
  overflow-y: auto;
  overflow-x: hidden; }

share/static/alice-dark.css  view on Meta::CPAN

  position: absolute;
  right: 52px;
  bottom: 51px;
  width: 80px;
  border-bottom: none;
  margin: 0;
  padding: 0;
  z-index: 903; }

div.color_picker span {
  cursor: pointer; }

div.color_picker div.colors {
  clear: both; }

div.color_picker div.colors span {
  float: left;
  display: block;
  width: 20px;
  height: 20px;
  margin: 0;

share/static/alice-dark.css  view on Meta::CPAN

  display: block; }

div.config div#tabset_data ul li {
  margin-bottom: 0.25em; }

div.config div.sidebar h2 {
  text-transform: uppercase;
  color: #cccccc;
  letter-spacing: 1px;
  font-size: 0.7em;
  cursor: default;
  font-weight: normal;
  padding: 5px 8px;
  margin: 0; }

div.config div.sidebar li {
  padding: 5px 8px;
  cursor: pointer;
  font-size: 0.8em; }

div.config div.sidebar li:hover {
  background: #3a3a3a; }

div.config div.sidebar li.active,
div.config div.sidebar li.disconnected.active,
div.config div.sidebar li.connected.active {
  background: #333333; }

share/static/alice-dark.css  view on Meta::CPAN

  padding: 0; }

.dropdown li span,
.dropdown li a {
  color: white;
  display: block;
  padding: 4px 10px;
  text-decoration: none; }

.dropdown li {
  cursor: pointer; }

.dropdown li a:hover {
  color: white; }

.dropdown ul li:hover {
  background: #3a3a3a; }

.dropdown > ul ul {
  display: none;
  right: 100%; }

share/static/alice-default.css  view on Meta::CPAN

  margin: 0;
  padding: 0;
  overflow: hidden;
  color: black;
  -webkit-text-size-adjust: none !important; }

img {
  border: none; }

ul#tabs li:hover {
  cursor: default; }

div#tab_bar .dropdown {
  opacity: 0;
  width: 24px;
  height: 24px;
  z-index: 905; }

div#join_button {
  position: absolute;
  bottom: 0px;
  right: 12px;
  width: 24px;
  height: 24px;
  background: url(image/sprites.png) -32px -36px no-repeat;
  cursor: pointer; }

div#join_button:hover {
  background: url(image/sprites.png) -32px -56px no-repeat; }

div#tab_bar div#tabset_dropdown {
  position: absolute;
  bottom: 0px;
  left: 0px;
  background: url(image/sprites.png) -29px 4px no-repeat;
  opacity: 1;
  cursor: pointer; }

div#tab_bar div#tabset_dropdown:hover {
  background: url(image/sprites.png) -29px -16px no-repeat; }

div#tab_bar .dropdown.active {
  opacity: 1;
  cursor: pointer; }

div#tab_menu_left {
  position: absolute;
  left: 24px;
  bottom: 0px;
  border-right: 1px solid #999999; }

div#tab_menu_left ul {
  left: 0px;
  right: auto; }

share/static/alice-default.css  view on Meta::CPAN

  background: url(image/sprites.png) -29px -236px no-repeat; }

div#config_menu {
  top: 0px;
  left: 0px;
  height: 17px;
  border: #fff;
  border: 1px solid #cccccc;
  border-bottom: 1px solid #555555;
  border-right: 1px solid #555555;
  cursor: pointer;
  position: absolute;
  z-index: 902;
  background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAaCAYAAAADiYpyAAADG0lEQVRYw+2ZS0hVURSGr9qVBipGDysaZUIRRQ9u70FlgwYZFTRp0ItIgqKixEERBE2i6A1FWUjSKKGoBiVZEEnRw8oKa9KLoIcQZWqW5teg/8DicM6596gHruiBhey19tp7r+/svfY61xgQGxBiAxAiBpEJtLpkRn...
  background-color: #999999;
  background-size: 33px 13px;
  width: 50px; }

div#config_menu > ul {
  margin-left: -1px; }

@media screen and (-webkit-device-pixel-ratio: 2) {
  div#config_menu {
    top: 0px;
    left: 0px;
    height: 17px;
    border: #fff;
    border: 1px solid #cccccc;
    border-bottom: 1px solid #555555;
    border-right: 1px solid #555555;
    cursor: pointer;
    position: absolute;
    z-index: 902;
    background: url(image/logo2x.png) center center no-repeat;
    -webkit-background-size: 33px 13px;
    background-color: #999999;
    width: 53px; } }
div#config_menu ul ul {
  left: 100%;
  right: auto;
  margin-left: -2px; }

share/static/alice-default.css  view on Meta::CPAN

  -webkit-transition-property: opacity, width;
  -webkit-transition-duration: 0.3s, 0.2s;
  -webkit-transition-timing-function: ease-in-out;
  -moz-transition-property: opacity, width;
  -moz-transition-duration: 0.3s, 0.2s;
  -moz-transition-timing-function: ease-in-out;
  border-radius: 2px;
  color: #222222;
  font-size: 14px;
  z-index: 902;
  cursor: pointer;
  opacity: 0; }

div#nicklist_toggle:hover {
  background-color: #cccccc; }

div#windows.nicklist div#nicklist_toggle {
  background-image: url(image/slider-right.png); }

div#nicklist_toggle.visible,
div#nicklist_toggle:hover,

share/static/alice-default.css  view on Meta::CPAN

div#windows.nicklist ul#nicklist {
  right: 0px;
  left: auto;
  visibility: visible; }

ul#nicklist li {
  display: block;
  padding: 3px 5px 0px 5px; }

ul#nicklist li a {
  cursor: pointer;
  color: black;
  font-size: 0.8em; }

div#input {
  background: #efefef;
  border-bottom: 1px solid #999999;
  border-top: 1px solid #aaaaaa;
  position: absolute;
  bottom: 24px;
  left: 0px;

share/static/alice-default.css  view on Meta::CPAN

div#input div.editor_toolbar button {
  display: block;
  float: left;
  color: #222222;
  line-height: 12px;
  font-size: 12px;
  margin: 0;
  padding: 4px 4px;
  text-align: center;
  background: none;
  cursor: pointer;
  border: none;
  color: #999999; }

div#input div.editor_toolbar button.colors:hover {
  background: none; }

div#input div.editor_toolbar button.colors {
  width: 14px;
  height: 14px;
  border: 2px solid black;

share/static/alice-default.css  view on Meta::CPAN

div.image a a.hideimg {
  position: absolute;
  white-space: nowrap;
  top: 0px;
  left: 0px;
  right: 0px;
  text-align: center;
  opacity: 0;
  color: #fff;
  padding: 4px 0px;
  cursor: pointer;
  font-size: 11px;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5); }

div.image a:hover a.hideimg {
  opacity: 1;
  background: rgba(0, 0, 0, 0.25); }

div.image a a.hideimg:hover {
  background: rgba(0, 0, 0, 0.5);
  opacity: 1; }

share/static/alice-default.css  view on Meta::CPAN

  border-left: none; }

ul.messages li.event div.left {
  font-weight: normal; }

ul.messages li.announce div.msg {
  color: #777;
  white-space: pre-wrap; }

div.msg img.audio {
  cursor: pointer;
  display: inline;
  padding: 0 4px;
  width: 16px;
  height: 16px;
  margin-bottom: -3px; }

a.nick {
  color: black;
  text-decoration: none; }

share/static/alice-default.css  view on Meta::CPAN

  position: absolute;
  top: 17px;
  right: 20px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 9px;
  letter-spacing: 1px;
  text-shadow: none;
  text-transform: uppercase; }

div#help div#helpclose:hover {
  cursor: pointer;
  color: #fff; }

div#help div#topics {
  position: absolute;
  top: 34px;
  bottom: 15px;
  left: 20px;
  right: 20px;
  overflow-y: auto;
  overflow-x: hidden; }

share/static/alice-default.css  view on Meta::CPAN

  position: absolute;
  right: 52px;
  bottom: 51px;
  width: 80px;
  border-bottom: none;
  margin: 0;
  padding: 0;
  z-index: 903; }

div.color_picker span {
  cursor: pointer; }

div.color_picker div.colors {
  clear: both; }

div.color_picker div.colors span {
  float: left;
  display: block;
  width: 20px;
  height: 20px;
  margin: 0;

share/static/alice-default.css  view on Meta::CPAN

  display: block; }

div.config div#tabset_data ul li {
  margin-bottom: 0.25em; }

div.config div.sidebar h2 {
  text-transform: uppercase;
  color: #777777;
  letter-spacing: 1px;
  font-size: 0.7em;
  cursor: default;
  font-weight: normal;
  padding: 5px 8px;
  margin: 0; }

div.config div.sidebar li {
  padding: 5px 8px;
  cursor: pointer;
  font-size: 0.8em; }

div.config div.sidebar li:hover {
  background: #cccccc; }

div.config div.sidebar li.active,
div.config div.sidebar li.disconnected.active,
div.config div.sidebar li.connected.active {
  background: #eeeeee; }

share/static/alice-default.css  view on Meta::CPAN

  padding: 0; }

.dropdown li span,
.dropdown li a {
  color: #222222;
  display: block;
  padding: 4px 10px;
  text-decoration: none; }

.dropdown li {
  cursor: pointer; }

.dropdown li a:hover {
  color: black; }

.dropdown ul li:hover {
  background: #cccccc; }

.dropdown > ul ul {
  display: none;
  right: 100%; }

share/static/alice-solarized.css  view on Meta::CPAN

  margin: 0;
  padding: 0;
  overflow: hidden;
  color: #073642;
  -webkit-text-size-adjust: none !important; }

img {
  border: none; }

ul#tabs li:hover {
  cursor: default; }

div#tab_bar .dropdown {
  opacity: 0;
  width: 24px;
  height: 24px;
  z-index: 905; }

div#join_button {
  position: absolute;
  bottom: 0px;
  right: 12px;
  width: 24px;
  height: 24px;
  background: url(image/sprites.png) -32px -36px no-repeat;
  cursor: pointer; }

div#join_button:hover {
  background: url(image/sprites.png) -32px -56px no-repeat; }

div#tab_bar div#tabset_dropdown {
  position: absolute;
  bottom: 0px;
  left: 0px;
  background: url(image/sprites.png) -29px 4px no-repeat;
  opacity: 1;
  cursor: pointer; }

div#tab_bar div#tabset_dropdown:hover {
  background: url(image/sprites.png) -29px -16px no-repeat; }

div#tab_bar .dropdown.active {
  opacity: 1;
  cursor: pointer; }

div#tab_menu_left {
  position: absolute;
  left: 24px;
  bottom: 0px;
  border-right: 1px solid #44555a; }

div#tab_menu_left ul {
  left: 0px;
  right: auto; }

share/static/alice-solarized.css  view on Meta::CPAN

  background: url(image/sprites.png) -29px -236px no-repeat; }

div#config_menu {
  top: 0px;
  left: 0px;
  height: 17px;
  border: #fff;
  border: 1px solid #93a1a1;
  border-bottom: 1px solid #002b36;
  border-right: 1px solid #002b36;
  cursor: pointer;
  position: absolute;
  z-index: 902;
  background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAaCAYAAAADiYpyAAADG0lEQVRYw+2ZS0hVURSGr9qVBipGDysaZUIRRQ9u70FlgwYZFTRp0ItIgqKixEERBE2i6A1FWUjSKKGoBiVZEEnRw8oKa9KLoIcQZWqW5teg/8DicM6596gHruiBhey19tp7r+/svfY61xgQGxBiAxAiBpEJtLpkRn...
  background-color: #657b83;
  background-size: 33px 13px;
  width: 50px; }

div#config_menu > ul {
  margin-left: -1px; }

@media screen and (-webkit-device-pixel-ratio: 2) {
  div#config_menu {
    top: 0px;
    left: 0px;
    height: 17px;
    border: #fff;
    border: 1px solid #93a1a1;
    border-bottom: 1px solid #002b36;
    border-right: 1px solid #002b36;
    cursor: pointer;
    position: absolute;
    z-index: 902;
    background: url(image/logo2x.png) center center no-repeat;
    -webkit-background-size: 33px 13px;
    background-color: #657b83;
    width: 53px; } }
div#config_menu ul ul {
  left: 100%;
  right: auto;
  margin-left: -2px; }

share/static/alice-solarized.css  view on Meta::CPAN

  -webkit-transition-property: opacity, width;
  -webkit-transition-duration: 0.3s, 0.2s;
  -webkit-transition-timing-function: ease-in-out;
  -moz-transition-property: opacity, width;
  -moz-transition-duration: 0.3s, 0.2s;
  -moz-transition-timing-function: ease-in-out;
  border-radius: 2px;
  color: white;
  font-size: 14px;
  z-index: 902;
  cursor: pointer;
  opacity: 0; }

div#nicklist_toggle:hover {
  background-color: #4b5e64; }

div#windows.nicklist div#nicklist_toggle {
  background-image: url(image/slider-right.png); }

div#nicklist_toggle.visible,
div#nicklist_toggle:hover,

share/static/alice-solarized.css  view on Meta::CPAN

div#windows.nicklist ul#nicklist {
  right: 0px;
  left: auto;
  visibility: visible; }

ul#nicklist li {
  display: block;
  padding: 3px 5px 0px 5px; }

ul#nicklist li a {
  cursor: pointer;
  color: #073642;
  font-size: 0.8em; }

div#input {
  background: #657b83;
  border-bottom: 1px solid #44555a;
  border-top: 1px solid #44555a;
  position: absolute;
  bottom: 24px;
  left: 0px;

share/static/alice-solarized.css  view on Meta::CPAN

div#input div.editor_toolbar button {
  display: block;
  float: left;
  color: white;
  line-height: 12px;
  font-size: 12px;
  margin: 0;
  padding: 4px 4px;
  text-align: center;
  background: none;
  cursor: pointer;
  border: none;
  color: #93a1a1; }

div#input div.editor_toolbar button.colors:hover {
  background: none; }

div#input div.editor_toolbar button.colors {
  width: 14px;
  height: 14px;
  border: 2px solid #073642;

share/static/alice-solarized.css  view on Meta::CPAN

div.image a a.hideimg {
  position: absolute;
  white-space: nowrap;
  top: 0px;
  left: 0px;
  right: 0px;
  text-align: center;
  opacity: 0;
  color: #fff;
  padding: 4px 0px;
  cursor: pointer;
  font-size: 11px;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5); }

div.image a:hover a.hideimg {
  opacity: 1;
  background: rgba(0, 0, 0, 0.25); }

div.image a a.hideimg:hover {
  background: rgba(0, 0, 0, 0.5);
  opacity: 1; }

share/static/alice-solarized.css  view on Meta::CPAN

  border-left: none; }

ul.messages li.event div.left {
  font-weight: normal; }

ul.messages li.announce div.msg {
  color: #777;
  white-space: pre-wrap; }

div.msg img.audio {
  cursor: pointer;
  display: inline;
  padding: 0 4px;
  width: 16px;
  height: 16px;
  margin-bottom: -3px; }

a.nick {
  color: #073642;
  text-decoration: none; }

share/static/alice-solarized.css  view on Meta::CPAN

  position: absolute;
  top: 17px;
  right: 20px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 9px;
  letter-spacing: 1px;
  text-shadow: none;
  text-transform: uppercase; }

div#help div#helpclose:hover {
  cursor: pointer;
  color: #fff; }

div#help div#topics {
  position: absolute;
  top: 34px;
  bottom: 15px;
  left: 20px;
  right: 20px;
  overflow-y: auto;
  overflow-x: hidden; }

share/static/alice-solarized.css  view on Meta::CPAN

  position: absolute;
  right: 52px;
  bottom: 51px;
  width: 80px;
  border-bottom: none;
  margin: 0;
  padding: 0;
  z-index: 903; }

div.color_picker span {
  cursor: pointer; }

div.color_picker div.colors {
  clear: both; }

div.color_picker div.colors span {
  float: left;
  display: block;
  width: 20px;
  height: 20px;
  margin: 0;

share/static/alice-solarized.css  view on Meta::CPAN

  display: block; }

div.config div#tabset_data ul li {
  margin-bottom: 0.25em; }

div.config div.sidebar h2 {
  text-transform: uppercase;
  color: #eee8d5;
  letter-spacing: 1px;
  font-size: 0.7em;
  cursor: default;
  font-weight: normal;
  padding: 5px 8px;
  margin: 0; }

div.config div.sidebar li {
  padding: 5px 8px;
  cursor: pointer;
  font-size: 0.8em; }

div.config div.sidebar li:hover {
  background: #4b5e64; }

div.config div.sidebar li.active,
div.config div.sidebar li.disconnected.active,
div.config div.sidebar li.connected.active {
  background: #4b5e64; }

share/static/alice-solarized.css  view on Meta::CPAN

  padding: 0; }

.dropdown li span,
.dropdown li a {
  color: white;
  display: block;
  padding: 4px 10px;
  text-decoration: none; }

.dropdown li {
  cursor: pointer; }

.dropdown li a:hover {
  color: #073642; }

.dropdown ul li:hover {
  background: #4b5e64; }

.dropdown > ul ul {
  display: none;
  right: 100%; }

share/static/alice.js  view on Meta::CPAN

      _toTextRange: function() {
        function adoptEndPoint(textRange, domRange, bStart) {
          var container = domRange[bStart ? 'startContainer' : 'endContainer'];
          var offset = domRange[bStart ? 'startOffset' : 'endOffset'], textOffset = 0;
          var anchorNode = DOMUtils.isDataNode(container) ? container : container.childNodes[offset];
          var anchorParent = DOMUtils.isDataNode(container) ? container.parentNode : container;

          if (container.nodeType == 3 || container.nodeType == 4)
            textOffset = offset;

          var cursorNode = domRange._document.createElement('a');
          if (anchorNode)
            anchorParent.insertBefore(cursorNode, anchorNode);
          else
            anchorParent.appendChild(cursorNode);
          var cursor = domRange._document.body.createTextRange();
          cursor.moveToElementText(cursorNode);
          cursorNode.parentNode.removeChild(cursorNode);

          textRange.setEndPoint(bStart ? 'StartToStart' : 'EndToStart', cursor);
          textRange[bStart ? 'moveStart' : 'moveEnd']('character', textOffset);
        }

        var textRange = this._document.body.createTextRange();
        adoptEndPoint(textRange, this, true);
        adoptEndPoint(textRange, this, false);
        return textRange;
      },

      _refreshProperties: function() {

share/static/alice.js  view on Meta::CPAN

          subRange.setEnd(this.range.endContainer, this.range.endOffset);
        return new RangeIterator(subRange);
      }
    };

    return Range;
  })();

  window.Range._fromTextRange = function(textRange, document) {
    function adoptBoundary(domRange, textRange, bStart) {
      var cursorNode = document.createElement('a'), cursor = textRange.duplicate();
      cursor.collapse(bStart);
      var parent = cursor.parentElement();
      do {
        parent.insertBefore(cursorNode, cursorNode.previousSibling);
        cursor.moveToElementText(cursorNode);
      } while (cursor.compareEndPoints(bStart ? 'StartToStart' : 'StartToEnd', textRange) > 0 && cursorNode.previousSibling);

      if (cursor.compareEndPoints(bStart ? 'StartToStart' : 'StartToEnd', textRange) == -1 && cursorNode.nextSibling) {
        cursor.setEndPoint(bStart ? 'EndToStart' : 'EndToEnd', textRange);
        domRange[bStart ? 'setStart' : 'setEnd'](cursorNode.nextSibling, cursor.text.length);
      } else {
        domRange[bStart ? 'setStartBefore' : 'setEndBefore'](cursorNode);
      }
      cursorNode.parentNode.removeChild(cursorNode);
    }

    var domRange = new Range(document);
    adoptBoundary(domRange, textRange, true);
    adoptBoundary(domRange, textRange, false);
    return domRange;
  }

  document.createRange = function() {
    return new Range(document);



( run in 0.321 second using v1.01-cache-2.11-cpan-4d50c553e7e )