<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css"
        integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ=="
        crossorigin="anonymous" referrerpolicy="no-referrer" />
</head>
</html>

]                 @   sY   d  d l  m Z Gd d   d  Z e d k rU d  d l m Z e d d d d	 d
 d S)    )idleConfc               @   sL   e  Z d  Z d d   Z d d   Z d d   Z d d   Z d	 d
   Z d S)Historyc             C   sl   | |  _  g  |  _ d  |  _ d  |  _ t j d d d d d  |  _ | j d |  j  | j d |  j	  d  S)Nmainr   cyclic   boolz<<history-previous>>z<<history-next>>)
texthistoryprefixpointerr   Z	GetOptionr   bindhistory_prevhistory_next)selfr    r   0/opt/alt/python35/lib64/python3.5/IdleHistory.py__init__   s    					zHistory.__init__c             C   s   |  j  d d  d S)NreverseFbreak)fetch)r   eventr   r   r   r      s    zHistory.history_nextc             C   s   |  j  d d  d S)Nr   Tr   )r   )r   r   r   r   r   r   #   s    zHistory.history_prevc             C   s;  t  |  j  } |  j } |  j } | d  k	 r | d  k	 r |  j j d d d  ss |  j j d d  |  j | k r d  } } |  j j d d  | d  k s | d  k r |  j j d d  } | r | } n# |  j r d
 } n |  j j	   d  St  |  } x| | rd n d 7} | d k  s,| | k r|  j j	   |  j rS| d k  rSd  S|  j j d d  | k r|  j j
 d d  |  j j d |  d  } } P|  j | } | d  |  | k r t  |  | k r |  j j
 d d  |  j j d |  Pq W|  j j d  |  j j d d d	  | |  _ | |  _ d  S)Ninsertz!=zend-1cZiomarkr   r   Zselz1.0endr   )lenr	   r   r
   r   ZcomparegetZmark_setr   Zbelldeleter   ZseeZ
tag_remove)r   r   Znhistr   r
   Znprefixitemr   r   r   r   (   sJ    		"
			
(	zHistory.fetchc             C   sm   | j    } t |  d k rW y |  j j |  Wn t k
 rF Yn X|  j j |  d  |  _ d  |  _ d  S)N   )stripr   r	   remove
ValueErrorappendr   r
   )r   sourcer   r   r   storeY   s    	zHistory.storeN)__name__
__module____qualname__r   r   r   r   r$   r   r   r   r   r      s
   1r   __main__)r   z"idlelib.idle_test.test_idlehistory	verbosityr   exitFN)Zidlelib.configHandlerr   r   r%   Zunittestr   r   r   r   r   <module>   s   a