
    \i'                         S r SSKJrJr  SSKJrJr   " S S\5      r " S S\5      r " S S	\5      r	 " S
 S\5      r
 " S S\5      rg)a  
Copyright 2011-2018 Kyle Lancaster | 2019 Patrick Eisoldt

Simplekml is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

    )Kmlablecheck)GxTimeStamp
GxTimeSpanc                   @   ^  \ rS rSrSrSU 4S jjrSS jrS rSrU =r	$ )	GxViewerOptions   zMEnables special viewer modes.

The arguments are the same as the properties.
c                 j   > [         [        U ]  5         / U l        Ub  U =R                  U-  sl        g g N)superr   __init__	gxoptions)selfr   	__class__s     Y/var/www/html/kml_chatgpt/mouzaenv/lib/python3.13/site-packages/simplekml/abstractview.pyr   GxViewerOptions.__init__   s0    ot-/ NNi'N !    c                 L    U R                   R                  [        X5      5        g)zPCreates a :class:`simplekml.GxOption` with name `name` and sets it to `enabled`.N)r   appendGxOption)r   nameenableds      r   newgxoptionGxViewerOptions.newgxoption"   s    ht56r   c                     S/nU R                    H"  nUR                  UR                  5       5        M$     UR                  S5        SR                  U5      $ )Nz<gx:ViewerOptions>z</gx:ViewerOptions> )r   r   __str__join)r   bufgxoptions      r   r   GxViewerOptions.__str__&   sH    #$HJJx'')* '

()wws|r   )r   r   )T)
__name__
__module____qualname____firstlineno____doc__r   r   r   __static_attributes____classcell__r   s   @r   r   r      s    (7 r   r   c                     ^  \ rS rSrSr           SU 4S jjr\S 5       r\R                  S 5       r\S 5       r	\	R                  S 5       r	\S 5       r
\
R                  S	 5       r
\S
 5       r\R                  S 5       r\S 5       r\R                  S 5       r\S 5       r\R                  S 5       r\S 5       r\R                  S 5       r\S 5       r\R                  \" \5      S 5       5       r\S 5       r\R                  \" \5      S 5       5       r\S 5       r\R                  S 5       r\S 5       r\R                  \" \5      S 5       5       rSrU =r$ )AbstractView.   zAbstract element, extended by :class:`simplekml.Camera` and :class:`simplekml.LookAt`

The arguments are the same as the properties.

 .. note::
   Not to be used directly.


c                 ^  > [         [        U ]  5         XR                  S'   X R                  S'   X0R                  S'   X@R                  S'   XPR                  S'   X`R                  S'   XpR                  S'   XR                  S'   XR                  S	'   XR                  S
'   XR                  S'   g )N	longitudelatitudealtitudeheadingtiltaltitudeModezgx:AltitudeModegx:TimeSpan_gx:TimeStamp_gx:horizFovgx:ViewerOptions_)r   r+   r   _kml)r   r.   r/   r0   r1   r2   altitudemodegxaltitudemode
gxtimespangxtimestamp
gxhorizfovgxvieweroptionsr   s               r   r   AbstractView.__init__8   s     	lD*,!*		+ (		* (		*&		) 		&$0		.!'5		#$$.		.!%0		/"#-		- )8		%&r   c                      U R                   S   $ )3Decimal degree value in WGS84 datum, accepts float.r.   r8   r   s    r   r.   AbstractView.longitudeQ   s     yy%%r   c                      XR                   S'   g )Nr.   rB   )r   r.   s     r   r.   rD   V   s    !*		+r   c                      U R                   S   $ )rA   r/   rB   rC   s    r   r/   AbstractView.latitudeZ        yy$$r   c                      XR                   S'   g )Nr/   rB   )r   r/   s     r   r/   rG   _        (		*r   c                      U R                   S   $ )z2Height above the earth in meters (m), accepts int.r0   rB   rC   s    r   r0   AbstractView.altitudec   rH   r   c                      XR                   S'   g )Nr0   rB   )r   r0   s     r   r0   rL   h   rJ   r   c                      U R                   S   $ )z)Rotation about the z axis, accepts float.r1   rB   rC   s    r   r1   AbstractView.headingl        yy##r   c                      XR                   S'   g )Nr1   rB   )r   r1   s     r   r1   rO   q       &		)r   c                      U R                   S   $ ))Rotation about the x axis, accepts float.r2   rB   rC   s    r   r2   AbstractView.tiltu        yy  r   c                      XR                   S'   g )Nr2   rB   )r   r2   s     r   r2   rU   z        		&r   c                      U R                   S   $ )zoSpecifies how the altitude for the Camera is interpreted.

Accepts :class:`simplekml.AltitudeMode` constants.

r3   rB   rC   s    r   r9   AbstractView.altitudemode~   s     yy((r   c                      XR                   S'   g )Nr3   rB   )r   r9   s     r   r9   rZ      s    $0		.!r   c                      U R                   S   $ )zSpecifies how the altitude for the Camera is interpreted.

With the addition of being relative to the sea floor.
Accepts :class:`simplekml.GxAltitudeMode` constants.

gx:altitudeModerB   rC   s    r   r:   AbstractView.gxaltitudemode   s     yy*++r   c                      XR                   S'   g )Nr]   rB   )r   	gxaltmodes     r   r:   r^      s    '0		#$r   c                 n    U R                   S   c  [        5       U R                   S'   U R                   S   $ )zJRepresents a single moment in time, accepts :class:`simplekml.GxTimeStamp`r5   )r8   r   rC   s    r   r<   AbstractView.gxtimestamp   s2     99_%-)4DIIo&yy))r   c                      XR                   S'   g )Nr5   rB   )r   r<   s     r   r<   rb      s     &1		/"r   c                 n    U R                   S   c  [        5       U R                   S'   U R                   S   $ )z5Period of time, accepts :class:`simplekml.GxTimeSpan`r4   )r8   r   rC   s    r   r;   AbstractView.gxtimespan   s2     99^$,(2DIIn%yy((r   c                      XR                   S'   g )Nr4   rB   )r   r;   s     r   r;   re      s     %/		.!r   c                      U R                   S   $ )rT   r6   rB   rC   s    r   r=   AbstractView.gxhorizfov   s     yy''r   c                      XR                   S'   g )Nr6   rB   )r   r=   s     r   r=   rh      s    #-		- r   c                 n    U R                   S   c  [        5       U R                   S'   U R                   S   $ )zJEnables special viewing modes , accepts :class:`simplekml.GxViewerOptions`r7   )r8   r   rC   s    r   r>   AbstractView.gxvieweroptions   s6     99()1-<->DII)*yy,--r   c                      XR                   S'   g )Nr7   rB   )r   r>   s     r   r>   rk      s     *9		%&r    )NNNNNNNNNNN)r"   r#   r$   r%   r&   r   propertyr.   setterr/   r0   r1   r2   r9   r:   r<   r   r   r;   r   r=   r>   r   r'   r(   r)   s   @r   r+   r+   .   sI     " $ ! !%92 & & + + % % __) ) % % __) ) $ $ ^^' ' ! ! 
[[! ! ) ) 1 1 , , 1 1 * * 
;1  1 ) ) 
:/  / ( ( . . . . 
?9  9r   r+   c                   d   ^  \ rS rSrSrSU 4S jjr\S 5       r\R                  S 5       rSr	U =r
$ )Camera   a  A virtual camera that views the scene.

The arguments are the same as the properties.

Basic Usage::

    import simplekml
    kml = simplekml.Kml()
    pnt = kml.newpoint()
    pnt.camera.latitude = 0.02
    pnt.camera.longitude = 0.012
    pnt.camera.altitude = 10000
    pnt.camera.tilt = 45
    pnt.camera.heading = 0
    pnt.camera.roll = 0
    pnt.camera.altitudemode = simplekml.AltitudeMode.relativetoground
    kml.save("Camera.kml")

Assignment Usage::

    import simplekml
    kml = simplekml.Kml()
    pnt = kml.newpoint()
    camera = simplekml.Camera(latitude=0.0, longitude=0.0, altitude=0.0, roll=0, tilt=45,
                              altitudemode=simplekml.AltitudeMode.relativetoground)
    pnt.camera = camera
    kml.save("Camera Alternative.kml")
c                 J   > [         [        U ]
  " S0 UD6  XR                  S'   g )Nrollrm   )r   rq   r   r8   )r   rt   kwargsr   s      r   r   Camera.__init__   s!    fd$.v. 		&r   c                      U R                   S   $ )z)Rotation about the y axis, accepts float.rt   rB   rC   s    r   rt   Camera.roll   rV   r   c                      XR                   S'   g )Nrt   rB   )r   rt   s     r   rt   rx      rX   r   rm   r   )r"   r#   r$   r%   r&   r   rn   rt   ro   r'   r(   r)   s   @r   rq   rq      s9    :! ! ! 
[[! !r   rq   c                   d   ^  \ rS rSrSrSU 4S jjr\S 5       r\R                  S 5       rSr	U =r
$ )LookAt   a  Positions the camera in relation to the object that is being viewed.

The arguments are the same as the properties (most inherited from
:class:`simplekml.AbstractView`)

Usage::

    import simplekml
    kml = simplekml.Kml()
    ls = kml.newlinestring(name='A LineString')
    ls.coords = [(18.333868,-34.038274,10.0), (18.370618,-34.034421,10.0)]
    ls.extrude = 1
    ls.altitudemode = simplekml.AltitudeMode.relativetoground
    ls.lookat.gxaltitudemode = simplekml.GxAltitudeMode.relativetoseafloor
    ls.lookat.latitude = -34.028242
    ls.lookat.longitude = 18.356852
    ls.lookat.range = 3000
    ls.lookat.heading = 56
    ls.lookat.tilt = 78
    kml.save("LookAt.kml")
c                 J   > [         [        U ]
  " S0 UD6  XR                  S'   g )Nrangerm   )r   r{   r   r8   )r   r~   ru   r   s      r   r   LookAt.__init__
  s!    fd$.v."		'r   c                      U R                   S   $ )z/Distance in meters from the point, accepts int.r~   rB   rC   s    r   r~   LookAt.range  s     yy!!r   c                      XR                   S'   g )Nr~   rB   )r   r~   s     r   r~   r     s    "		'r   rm   r   )r"   r#   r$   r%   r&   r   rn   r~   ro   r'   r(   r)   s   @r   r{   r{      s9    ,# " " \\# #r   r{   c                      ^  \ rS rSrSrSrSrSrSU 4S jjr\	S 5       r
\
R                  S 5       r
\	S	 5       r\R                  S
 5       rS rSrU =r$ )r   i  zdChild element of :class:`simplekml.GxViewerOptions`.

The arguments are the same as the properties.

streetviewhistoricalimagerysunlightc                 >   > [         [        U ]  5         UUS.U l        g )N)r   r   )r   r   r   r8   )r   r   r   r   s      r   r   GxOption.__init__!  s    h&(! ')	r   c                      U R                   S   $ )zName of the effect being applied.

The following strings can be used :attr:`simplekml.GxOption.streetview`,
:attr:`simplekml.GxOption.historicalimagery` or :attr:`simplekml.GxOption.sunlight`
r   rB   rC   s    r   r   GxOption.name&  s     yy  r   c                      XR                   S'   g )Nr   rB   )r   r   s     r   r   r   /  rX   r   c                      U R                   S   $ )z5Whether the effect must be turned on or off, boolean.r   rB   rC   s    r   r   GxOption.enabled3  rP   r   c                      XR                   S'   g )Nr   rB   )r   r   s     r   r   r   8  rR   r   c                 p    SnU R                   S   (       a  SnSR                  U R                   S   U5      $ )N0r   1z0<gx:option name="{0}" enabled="{1}"></gx:option>r   )r8   format)r   enabledTexts     r   r   GxOption.__str__<  s6    99YKAHHSYIZ\ghhr   rB   )NF)r"   r#   r$   r%   r&   r   r   r   r   rn   r   ro   r   r   r'   r(   r)   s   @r   r   r     s     J+H)
 ! ! 
[[! ! $ $ ^^' 'i ir   r   N)r&   simplekml.baser   r   simplekml.timeprimitiver   r   r   r+   rq   r{   r   rm   r   r   <module>r      sU   $ * ;g .V97 V9r)!\ )!X"#\ "#J(iw (ir   