code
stringlengths
114
1.05M
path
stringlengths
3
312
quality_prob
float64
0.5
0.99
learning_prob
float64
0.2
1
filename
stringlengths
3
168
kind
stringclasses
1 value
import warnings from abc import ABC, abstractmethod from collections import deque from threading import Event, Lock, Semaphore from typing import TypeVar, List, final, Optional, Iterator T = TypeVar("T") class ResponseHandlerBase(Iterator[T], ABC): num_receivers: Optional[int] = None _num_received_results: i...
/rin_curium-0.2.0-py3-none-any.whl/rin/curium/response_handler_base.py
0.88251
0.153771
response_handler_base.py
pypi
from abc import ABC, abstractmethod from typing import Optional, Iterable class IConnection(ABC): @abstractmethod def connect(self) -> str: """ Connect to the backend server. :return: A unique id for node :raises ~exc.ConnectionFailedError: fail to connect. """ @...
/rin_curium-0.2.0-py3-none-any.whl/rin/curium/iconnection.py
0.946609
0.344761
iconnection.py
pypi
import numbers from datetime import datetime from typing import Dict, Any, Mapping, Callable, Union from .advanced_json_encoder import IResolver, ResolveError, ResolverPriority from .typing import JSONType, JSONSerializable __all__ = ["JSONSerializableResolver", "NumberResolver", "IterableResolver", "DateTimeResolver...
/rin_jsonutils-1.1.0-py3-none-any.whl/rin/jsonutils/resolvers.py
0.743727
0.154823
resolvers.py
pypi
import abc import enum from typing import Dict, Any, List from json import JSONEncoder from .typing import JSONType __all__ = ["AdvancedJSONEncoder", "IResolver", "ResolverPriority", "ResolveError"] class ResolverPriority(enum.IntEnum): LOW_BOUND = 1000 LOWEST = 1000 LOW = 750 MEDIUM = 500 HIGH ...
/rin_jsonutils-1.1.0-py3-none-any.whl/rin/jsonutils/advanced_json_encoder.py
0.724773
0.2139
advanced_json_encoder.py
pypi
from typing import AsyncGenerator, List import aiohttp import bs4 TAGS_PER_META = 48 IMAGES_PER_TAG = 24 HEADERS = {'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:64.0)' 'Gecko/20100101 Firefox/64.0'} async def get(query, **kwargs) -> bs4.BeautifulSoup: kwargs = '?'.join([f'...
/rin_zerochan-0.1.0-py3-none-any.whl/src/scrap.py
0.589126
0.209106
scrap.py
pypi
from typing import AsyncGenerator, List import aiohttp import bs4 TAGS_PER_META = 48 IMAGES_PER_TAG = 24 HEADERS = {'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:64.0)' 'Gecko/20100101 Firefox/64.0'} async def get(query, **kwargs) -> bs4.BeautifulSoup: kwargs = '?'.join([f'...
/rin_zerochan-0.1.0-py3-none-any.whl/rin_zerochan/scrap.py
0.596081
0.206694
scrap.py
pypi
"""Python Ring Other (Intercom) wrapper.""" import logging import time import uuid from ring_doorbell.generic import RingGeneric from ring_doorbell.const import ( INTERCOM_ALLOWED_USERS, INTERCOM_INVITATIONS_DELETE_ENDPOINT, INTERCOM_INVITATIONS_ENDPOINT, INTERCOM_KINDS, INTERCOM_OPEN_ENDPOINT, ) ...
/ring_doorbell_intercom-0.7.3.tar.gz/ring_doorbell_intercom-0.7.3/ring_doorbell/other.py
0.893181
0.182044
other.py
pypi
"""Python Ring Chime wrapper.""" import logging from ring_doorbell.generic import RingGeneric from ring_doorbell.const import ( CHIMES_ENDPOINT, CHIME_VOL_MIN, CHIME_VOL_MAX, LINKED_CHIMES_ENDPOINT, MSG_VOL_OUTBOUND, TESTSOUND_CHIME_ENDPOINT, CHIME_TEST_SOUND_KINDS, KIND_DING, CHIME...
/ring_doorbell_intercom-0.7.3.tar.gz/ring_doorbell_intercom-0.7.3/ring_doorbell/chime.py
0.891911
0.152347
chime.py
pypi
"""Python Ring RingGeneric wrapper.""" import logging _LOGGER = logging.getLogger(__name__) # pylint: disable=useless-object-inheritance class RingGeneric(object): """Generic Implementation for Ring Chime/Doorbell.""" # pylint: disable=redefined-builtin def __init__(self, ring, id): """Initializ...
/ring_doorbell_intercom-0.7.3.tar.gz/ring_doorbell_intercom-0.7.3/ring_doorbell/generic.py
0.922957
0.155816
generic.py
pypi
"""Python Ring Chime wrapper.""" import logging from ring_doorbell.generic import RingGeneric from ring_doorbell.const import ( CHIMES_ENDPOINT, CHIME_VOL_MIN, CHIME_VOL_MAX, LINKED_CHIMES_ENDPOINT, MSG_VOL_OUTBOUND, TESTSOUND_CHIME_ENDPOINT, CHIME_TEST_SOUND_KINDS, KIND_DING, CHIME...
/ring_doorbell-0.7.2.tar.gz/ring_doorbell-0.7.2/ring_doorbell/chime.py
0.891911
0.152347
chime.py
pypi
"""Python Ring RingGeneric wrapper.""" import logging _LOGGER = logging.getLogger(__name__) # pylint: disable=useless-object-inheritance class RingGeneric(object): """Generic Implementation for Ring Chime/Doorbell.""" # pylint: disable=redefined-builtin def __init__(self, ring, id): """Initializ...
/ring_doorbell-0.7.2.tar.gz/ring_doorbell-0.7.2/ring_doorbell/generic.py
0.922957
0.155816
generic.py
pypi
# ringbuf A lock-free, single-producer, single-consumer, ring buffer for Python and Cython. [![Test](https://github.com/elijahr/ringbuf/actions/workflows/test.yml/badge.svg)](https://github.com/elijahr/ringbuf/actions/workflows/test.yml) [![PyPI version](https://badge.fury.io/py/ringbuf.svg)](https://badge.fury.io/py...
/ringbuf-2.6.0.tar.gz/ringbuf-2.6.0/README.md
0.58059
0.946892
README.md
pypi
from dataclasses_json.api import DataClassJsonMixin from datetime import date from datetime import datetime from datetime import time from typing import * DT = TypeVar('DT', date, time, datetime) K = TypeVar('K') T = TypeVar('T') V = TypeVar('V') class DiscriminatorDecoderError(ValueError): pass class Unregistere...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/utils.py
0.799442
0.196942
utils.py
pypi
from ._15 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class CallParkPartyResponseOwner(DataClassJsonMixin): """ Data on a call owner """ account_id: Optional[str] = None """ Internal identifier of an account that monitors a call """ extension_id: Optional[str] = None ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_16.py
0.726426
0.201361
_16.py
pypi
from ._2 import * class ExtensionCreationRequestSetupWizardState(Enum): """ Specifies extension configuration wizard state (web service setup). """ NotStarted = 'NotStarted' Incomplete = 'Incomplete' Completed = 'Completed' @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ExtensionC...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_3.py
0.809012
0.222679
_3.py
pypi
from ._5 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ListCompanyActiveCallsResponseRecordsItemLegsItemMessage(DataClassJsonMixin): """ Linked message (Fax/Voicemail) """ id: Optional[str] = None """ Internal identifier of a message """ type: Optional[str] = None ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_6.py
0.76782
0.240786
_6.py
pypi
from ._3 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ScimErrorResponse(DataClassJsonMixin): detail: Optional[str] = None """ detail error message """ schemas: Optional[List[ScimErrorResponseSchemasItem]] = None scim_type: Optional[ScimErrorResponseScimType] = None "...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_4.py
0.722723
0.160529
_4.py
pypi
from ._9 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class CreateAnsweringRuleRequestQueueFixedOrderAgentsItem(DataClassJsonMixin): extension: Optional[CreateAnsweringRuleRequestQueueFixedOrderAgentsItemExtension] = None index: Optional[int] = None """ Ordinal of an agent (call queue ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_10.py
0.763836
0.180071
_10.py
pypi
from ..utils import datetime_decoder from ..utils import discriminator_decoder from dataclasses import dataclass from dataclasses import field from dataclasses_json.api import DataClassJsonMixin from dataclasses_json.api import LetterCase from dataclasses_json.api import dataclass_json from dataclasses_json.cfg import ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_1.py
0.857902
0.483892
_1.py
pypi
from ._11 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ListExtensionGrantsResponsePaging(DataClassJsonMixin): """ Information on paging """ page: Optional[int] = None """ The current page number. 1-indexed, so the first page is 1 by default. May be omitted if result ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_12.py
0.808672
0.45302
_12.py
pypi
from ._10 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ListStandardGreetingsResponseRecordsItemNavigationNextPage(DataClassJsonMixin): """ Canonical URI for the next page of the list """ uri: Optional[str] = None @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class Li...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_11.py
0.829803
0.39905
_11.py
pypi
from ._13 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ReadUserVideoConfigurationResponse(DataClassJsonMixin): provider: Optional[ReadUserVideoConfigurationResponseProvider] = None """ Video provider of the user """ class UpdateUserVideoConfigurationRequestProvider(Enum): "...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_14.py
0.80871
0.223335
_14.py
pypi
from ._1 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class GlipCreatePost(DataClassJsonMixin): activity: Optional[str] = None title: Optional[str] = None """ Title of a message. (Can be set for bot's messages only). """ text: Optional[str] = None """ Text of a post """ ...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_2.py
0.782746
0.393385
_2.py
pypi
from ._12 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class UpdateConferencingSettingsResponse(DataClassJsonMixin): uri: Optional[str] = None """ Canonical URI of a conferencing """ allow_join_before_host: Optional[bool] = None """ Determines if host user allows conference pa...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_13.py
0.771413
0.322659
_13.py
pypi
from ._8 import * @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class ListGlipPostsResponseNavigation(DataClassJsonMixin): prev_page_token: Optional[str] = None """ Previous page token. To get previous page, user should pass one of returned token in next request and, in turn, required page w...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_9.py
0.755186
0.296861
_9.py
pypi
from ._7 import * class ReadGlipPostResponseMentionsItemType(Enum): """ Type of mentions """ Person = 'Person' Team = 'Team' File = 'File' Link = 'Link' Event = 'Event' Task = 'Task' Note = 'Note' Card = 'Card' @dataclass_json(letter_case=LetterCase.CAMEL) @dataclass class Rea...
/ringcentral_async_client-1.0.3-py3-none-any.whl/ringcentral_async_client/_code_gen/model/_8.py
0.760651
0.300177
_8.py
pypi
# [RingCentral chatbot framework for Python](https://github.com/ringcentral/ringcentral-chatbot-python) <!-- omit in toc --> [![Build Status](https://travis-ci.org/ringcentral/ringcentral-chatbot-python.svg?branch=test)](https://travis-ci.org/ringcentral/ringcentral-chatbot-python) Welcome to the RingCentral Chatbot ...
/ringcentral_bot_framework-0.7.2.tar.gz/ringcentral_bot_framework-0.7.2/README.md
0.62395
0.933249
README.md
pypi
# ringcentral-python RingCentral Python Client library Only Python 3.x is supported. ## Getting help and support If you are having difficulty using this SDK, or working with the RingCentral API, please visit our [developer community forums](https://community.ringcentral.com/spaces/144/) for help and to get quick a...
/ringcentral_client-0.7.0.tar.gz/ringcentral_client-0.7.0/README.md
0.405096
0.720909
README.md
pypi
# ringcentral-python [![Build status](https://api.travis-ci.org/tylerlong/ringcentral-python.svg?branch=master)](https://travis-ci.org/tylerlong/ringcentral-python) [![Coverage Status](https://coveralls.io/repos/github/tylerlong/ringcentral-python/badge.svg?branch=master)](https://coveralls.io/github/tylerlong/ringcen...
/ringcentral_client-0.6.0.tar.gz/ringcentral_client-0.6.0/README.md
0.414069
0.71566
README.md
pypi
from typing import Dict, Union, Type, Optional, Any, TYPE_CHECKING from _ringding.messages import (ErrorResponse, Message, RESPONSE_TYPES) if TYPE_CHECKING: from _ringding.server import RdServer class _ApiEntry: """Proxy object for API entrypoint.""" pass class BaseClient: """ The Client base....
/ringding-0.3.2.tar.gz/ringding-0.3.2/src/_ringding/client/base.py
0.929832
0.238317
base.py
pypi
# RingsPy [![Python 3](https://img.shields.io/static/v1?label=Python&logo=Python&color=3776AB&message=3)](https://www.python.org/) [![PyPI version](https://badge.fury.io/py/ringspy.svg)](https://badge.fury.io/py/ringspy) [![Anaconda-Server Badge](https://anaconda.org/conda-forge/ringspy/badges/version.svg)](https://ana...
/ringspy-0.4.2.tar.gz/ringspy-0.4.2/README.md
0.652241
0.992837
README.md
pypi
![ringtail logo final](https://user-images.githubusercontent.com/41704502/170797800-53a9d94a-932e-4936-9bea-e2d292b0c62b.png) # Ringtail Package for creating SQLite database from virtual screening results, performing filtering, and exporting results. Compatible with [AutoDock-GPU](https://github.com/ccsb-scripps/Aut...
/ringtail-1.0.0-py3-none-any.whl/ringtail-1.0.0.data/data/README.md
0.415017
0.970909
README.md
pypi
========================= Transaction tree analysis ========================= Mitchell P. Krawiec-Thayer (@isthmus) // Noncesense Research Lab This library enables passive deanonymization of Monero-style blockchains for true spends revealed by "differ-by-one" ring pair analysis (described below). The analysis engine ...
/ringxor-0.0.2.3.tar.gz/ringxor-0.0.2.3/README.rst
0.919331
0.66341
README.rst
pypi
import json from django.contrib.auth.models import AnonymousUser from graphene import Schema from graphql import GraphQLError from graphene import Mutation from .models import MutationCommit import re import functools def commit(mutation_name): def decorator(func): def wrapper(*args, **kwargs): ...
/rinit_graphql_extention-0.1.2.tar.gz/rinit_graphql_extention-0.1.2/rinit_graphql_extention/inter_layer.py
0.435661
0.158467
inter_layer.py
pypi
import numpy as np import plotly.graph_objects as go def rink(setting = "full", vertical = False): ''' Function to plot rink in Plotly. Takes 2 arguments : setting : full (default) for full ice, offense positive half of the ice, ozone positive quarter of ice, defense for negative half of the ice, dzone fo...
/rink_plotly-0.1.0-py3-none-any.whl/rink_plotly-0.1.0.data/scripts/rink_plot.py
0.661376
0.581719
rink_plot.py
pypi
import numpy as np import plotly.graph_objects as go def rink(setting = "full", vertical = False): ''' Function to plot rink in Plotly. Takes 2 arguments : setting : full (default) for full ice, offense positive half of the ice, ozone positive quarter of ice, defense for negative half of the ice, dzone fo...
/rink_plotly-0.1.0-py3-none-any.whl/rink_plotly/rink_plot.py
0.661376
0.581719
rink_plot.py
pypi
.. _styling: Element Styling =============== This section describes how styles defined in a style sheet are applied to document elements. Understanding how this works will help you when designing a custom style sheet. rinohtype's style sheets are heavily inspired by CSS_, but add some additional functionality. Simil...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/doc/elementstyling.rst
0.945083
0.785761
elementstyling.rst
pypi
.. _basic_styling: Basic Document Styling ====================== rinohtype allows for fine-grained control over the style of its output. Most aspects of a document's style can be controlled by style sheet files and template configuration files which are being introduced in this chapter. These files are plain text fil...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/doc/basicstyling.rst
0.91153
0.806205
basicstyling.rst
pypi
from .attribute import Attribute, OptionSet, Bool from .paragraph import ParagraphBase, ParagraphStyle from .style import Style from .text import StyledText __all__ = ['NumberStyle', 'Label', 'NumberedParagraph', 'format_number'] class NumberFormat(OptionSet): values = (None, 'number', 'symbol', 'lowercase char...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/number.py
0.734024
0.196036
number.py
pypi
import binascii import struct from itertools import repeat from .attribute import AcceptNoneAttributeType, ParseError __all__ = ['Color', 'HexColor', 'BLACK', 'WHITE', 'RED', 'GREEN', 'BLUE', 'Gray', 'GRAY10', 'GRAY25', 'GRAY50', 'GRAY75', 'GRAY90'] class Color(AcceptNoneAttributeType): def __init_...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/color.py
0.746046
0.278212
color.py
pypi
from .attribute import AttributeType, ParseError from .dimension import Dimension, INCH, MM __all__ = ['Paper', 'A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'A6', 'A7', 'A8', 'A9', 'A10', 'LETTER', 'LEGAL', 'JUNIOR_LEGAL', 'LEDGER', 'TABLOID'] class Paper(AttributeType): """Defines a paper size. ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/paper.py
0.740644
0.311636
paper.py
pypi
from itertools import chain from .attribute import Attribute, Bool, Integer, OverrideDefault from .draw import Line, LineStyle from .element import create_destination from .flowable import GroupedFlowables, StaticGroupedFlowables from .flowable import PageBreak, PageBreakStyle from .flowable import LabeledFlowable, ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/structure.py
0.721645
0.230162
structure.py
pypi
from .attribute import Attribute from .dimension import Dimension, PT from .element import DocumentElement from .flowable import Flowable, FlowableStyle from .layout import VirtualContainer from .style import StyledMeta from .util import NotImplementedAttribute __all__ = ['InlineFlowableException', 'InlineFlowable'...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/inline.py
0.646237
0.253347
inline.py
pypi
from .attribute import Attribute, AcceptNoneAttributeType, ParseError from .color import Color, BLACK, GRAY90 from .style import Style, Styled from .dimension import Dimension, PT __all__ = ['Stroke', 'LineStyle', 'Line', 'ShapeStyle', 'Shape', 'Polygon', 'Rectangle'] class Stroke(AcceptNoneAttributeTy...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/draw.py
0.892135
0.303648
draw.py
pypi
import inspect import re import sys from .attribute import AcceptNoneAttributeType, ParseError from collections import OrderedDict from token import PLUS, MINUS, NUMBER, NAME, OP __all__ = ['Dimension', 'PT', 'PICA', 'INCH', 'MM', 'CM', 'PERCENT', 'QUARTERS'] class DimensionType(type): """Maps compa...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/dimension.py
0.743541
0.412471
dimension.py
pypi
from .annotation import NamedDestination from .warnings import warn __all__ = ['DocumentElement', 'Location'] class Location(object): def __init__(self, document_element): self.location = document_element.__class__.__name__ class DocumentElement(object): """An element that is directly or indirec...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/element.py
0.887741
0.244724
element.py
pypi
import re from ast import literal_eval from html.entities import name2codepoint from token import NAME, STRING, NEWLINE, LPAR, RPAR, ENDMARKER from .attribute import (AttributeType, Attribute, Bool, Integer, AcceptNoneAttributeType, ParseError) from .color import Color, BLACK from .dimension i...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/text.py
0.675444
0.158044
text.py
pypi
import os from ast import literal_eval from functools import partial from token import LPAR, RPAR, NAME, EQUAL, NUMBER, ENDMARKER, STRING, COMMA from .attribute import (Attribute, AcceptNoneAttributeType, Integer, OptionSet, AttributesDictionary, ParseError) from .color import RED from .dim...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/image.py
0.799833
0.307904
image.py
pypi
import re from collections import OrderedDict from configparser import ConfigParser from io import BytesIO from itertools import chain from pathlib import Path from token import NUMBER, ENDMARKER, MINUS, PLUS, NAME from tokenize import tokenize, ENCODING from warnings import warn from .util import (NamedDescriptor,...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/attribute.py
0.685002
0.262422
attribute.py
pypi
from collections import Iterable from itertools import chain from functools import partial from math import sqrt from .attribute import Attribute, OptionSet, OverrideDefault, Integer, Bool from .dimension import DimensionBase as DimBase from .draw import Line, Rectangle, ShapeStyle, LineStyle from .flowable import F...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/table.py
0.740737
0.223547
table.py
pypi
from collections import deque from contextlib import contextmanager from copy import copy from .dimension import Dimension, PT, DimensionAddition from .util import ContextManager __all__ = ['Container', 'FlowablesContainer', 'ChainedContainer', 'DownExpandingContainer', 'InlineDownExpandingContainer', ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/layout.py
0.847242
0.467089
layout.py
pypi
from copy import copy from itertools import chain, tee from token import NAME from .attribute import Attribute, OptionSet, Bool, OverrideDefault from .color import Color from .dimension import Dimension, PT, DimensionBase from .draw import ShapeStyle, Rectangle, Line, LineStyle, Stroke from .layout import (InlineDownE...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/flowable.py
0.866458
0.303971
flowable.py
pypi
from .attribute import Attribute, Bool from .flowable import GroupedFlowables, GroupedFlowablesStyle, DummyFlowable from .paragraph import Paragraph from .reference import Reference from .strings import StringField from .structure import Section, Heading, SectionTitles from .style import Styled from .text import Mixe...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/index.py
0.602296
0.219693
index.py
pypi
import os import re import struct from binascii import unhexlify from io import BytesIO from warnings import warn from . import Font, GlyphMetrics, LeafGetter, MissingGlyphException from .mapping import UNICODE_TO_GLYPH_NAME, ENCODINGS from ..font.style import FontVariant from ..util import cached from ..warnings ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/type1.py
0.459319
0.207315
type1.py
pypi
import hashlib, math, io, struct from datetime import datetime, timedelta from collections import OrderedDict from ...util import all_subclasses def create_reader(data_format, process_struct=lambda data: data[0]): data_struct = struct.Struct('>' + data_format) def reader(file, **kwargs): data = dat...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/parse.py
0.642096
0.335079
parse.py
pypi
import struct from binascii import hexlify from io import BytesIO def grab(file, data_format): data = file.read(struct.calcsize(data_format)) return struct.unpack('>' + data_format, data) card8 = lambda file: grab(file, 'B')[0] card16 = lambda file: grab(file, 'h')[0] offsize = card8 def offset(offset_s...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/cff.py
0.476092
0.307501
cff.py
pypi
import struct from .parse import OpenTypeTable, MultiFormatTable, Record from .parse import int16, uint16, ushort, ulong, Packed from .parse import array, context, context_array, indirect, indirect_array from .layout import LayoutTable, Coverage, ClassDefinition, Device from ...util import cached_property class Va...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/gpos.py
0.527073
0.266753
gpos.py
pypi
from .parse import OpenTypeTable, MultiFormatTable from .parse import uint16, ushort, ulong, glyph_id, array, indirect from .parse import context_array, indirect_array from .layout import LayoutTable from .layout import Coverage # Single substitution (subtable format 1) class SingleSubTable(MultiFormatTable): e...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/gsub.py
0.593963
0.255547
gsub.py
pypi
import struct from .parse import OpenTypeTable, MultiFormatTable, Record from .parse import byte, ushort, short, ulong, fixed, fword, ufword, uint24 from .parse import longdatetime, string, array, indirect, context_array, Packed from .macglyphs import MAC_GLYPHS from . import ids class HeadTable(OpenTypeTable): ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/required.py
0.608245
0.25097
required.py
pypi
from .parse import OpenTypeTable, MultiFormatTable, Record, context_array from .parse import fixed, array, uint16, tag, glyph_id, offset, indirect, Packed class ListRecord(Record): entries = [('Tag', tag), ('Offset', offset)] def parse_value(self, file, file_offset, entry_type): self...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/font/opentype/layout.py
0.478773
0.301169
layout.py
pypi
from itertools import chain from ..attribute import AttributesDictionary from ..flowable import StaticGroupedFlowables from ..util import NotImplementedAttribute __all__ = ['TreeNode', 'InlineNode', 'BodyNode', 'BodySubNode', 'GroupingNode', 'DummyNode', 'TreeNodeMeta', 'Reader'] class TreeNode(object...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/__init__.py
0.640523
0.253988
__init__.py
pypi
import re from ... import styleds from ...annotation import HyperLink, NamedDestination from . import EPubInlineNode, EPubBodyNode, EPubGroupingNode class Body(EPubBodyNode): pass class Section(EPubGroupingNode): grouped_flowables_class = styleds.Section class Div(EPubGroupingNode): grouped_flowab...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/epub/nodes.py
0.418935
0.365995
nodes.py
pypi
import os import re from urllib.parse import urljoin from urllib.request import pathname2url from ...styleds import Paragraph from ...text import MixedStyledText from ...util import NotImplementedAttribute from ... import DATA_PATH from .. import (TreeNode, InlineNode, BodyNode, BodySubNode, GroupingNode, ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/xml/__init__.py
0.509032
0.189859
__init__.py
pypi
from . import (DocBookNode, DocBookInlineNode, DocBookBodyNode, DocBookGroupingNode) from ...reference import TITLE, PAGE from ... import styleds class DocumentRoot(DocBookBodyNode): pass class Article(DocumentRoot): pass class Book(DocumentRoot): pass class Info(DocBookBodyNode):...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/docbook/nodes.py
0.544317
0.342187
nodes.py
pypi
import re from datetime import datetime import rinoh as rt from . import (DocutilsInlineNode, DocutilsNode, DocutilsBodyNode, DocutilsGroupingNode, DocutilsDummyNode) from ...dimension import DimensionUnit, INCH, CM, MM, PT, PICA, PERCENT from ...util import intersperse # Support for the following...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/rst/nodes.py
0.503174
0.249596
nodes.py
pypi
from pathlib import Path from docutils.core import publish_doctree from docutils.io import FileInput from docutils.parsers.rst import Parser as ReStructuredTextParser from ...document import DocumentTree from ...text import MixedStyledText from .. import (TreeNode, TreeNodeMeta, InlineNode, BodyNode, BodySubNode, ...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/frontend/rst/__init__.py
0.54359
0.22212
__init__.py
pypi
import codecs def search_function(encoding): if encoding == 'pdf_doc': return getregentry() codecs.register(search_function) ### Codec APIs class Codec(codecs.Codec): def encode(self, input, errors='strict'): return codecs.charmap_encode(input, errors, encoding_table) def decode(se...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/backend/pdf/pdfdoccodec.py
0.447943
0.171027
pdfdoccodec.py
pypi
from io import SEEK_CUR from pathlib import Path from struct import Struct, unpack, calcsize from warnings import warn from ..cos import Name, Array, Stream, Integer from ..filter import DCTDecode, FlateDecode from . import XObjectImage, DEVICE_GRAY, DEVICE_RGB, DEVICE_CMYK from .icc import SRGB, UNCALIBRATED, get_i...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/src/rinoh/backend/pdf/xobject/jpeg.py
0.605216
0.244667
jpeg.py
pypi
CommonMark ========== CommonMark is a rationalized version of Markdown syntax, with a [spec][the spec] and BSD-licensed reference implementations in C and JavaScript. [Try it now!](http://try.commonmark.org/) [the spec]: http://spec.commonmark.org/ For more details, see <http://commonmark.org>. This repository co...
/rinohtype-reloaded-0.3.3.tar.gz/rinohtype-reloaded-0.3.3/examples/commonmark/README.md
0.812942
0.832237
README.md
pypi
.. _styling: Element Styling =============== This section describes how styles defined in a style sheet are applied to document elements. Understanding how this works will help you when designing a custom style sheet. rinohtype's style sheets are heavily inspired by CSS_, but add some additional functionality. Simil...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/doc/elementstyling.rst
0.945083
0.785761
elementstyling.rst
pypi
.. _basic_styling: Basic Document Styling ====================== rinohtype allows for fine-grained control over the style of its output. Most aspects of a document's style can be controlled by style sheet files and template configuration files which are being introduced in this chapter. These files are plain text fil...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/doc/basicstyling.rst
0.91153
0.806205
basicstyling.rst
pypi
from copy import copy from .attribute import Attribute, OptionSet, Bool, ParseError from .style import Style from .text import StyledText __all__ = ['NumberFormat', 'Label', 'LabelStyle', 'NumberStyle', 'format_number'] # number: plain arabic numbers (1, 2, 3, ...) # lowercase character: lowercase let...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/number.py
0.793146
0.231484
number.py
pypi
import binascii import struct from itertools import repeat from .attribute import AcceptNoneAttributeType, ParseError __all__ = ['Color', 'HexColor', 'BLACK', 'WHITE', 'RED', 'GREEN', 'BLUE', 'Gray', 'GRAY10', 'GRAY25', 'GRAY50', 'GRAY75', 'GRAY90'] class Color(AcceptNoneAttributeType): """Color de...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/color.py
0.816589
0.369059
color.py
pypi
from .attribute import AttributeType, ParseError from .dimension import Dimension, INCH, MM __all__ = ['Paper', 'A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'A6', 'A7', 'A8', 'A9', 'A10', 'LETTER', 'LEGAL', 'JUNIOR_LEGAL', 'LEDGER', 'TABLOID'] class Paper(AttributeType): """Defines a paper size. ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/paper.py
0.741955
0.308841
paper.py
pypi
import string from ast import literal_eval from collections import OrderedDict, namedtuple from contextlib import suppress from itertools import chain from pathlib import Path from .attribute import (WithAttributes, AttributesDictionary, RuleSet, RuleSetFile, Configurable, ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/style.py
0.825519
0.153771
style.py
pypi
import re from itertools import chain, zip_longest from .annotation import NamedDestinationLink from .attribute import Attribute, Bool, OptionSet, OverrideDefault from .flowable import (Flowable, LabeledFlowable, DummyFlowable, LabeledFlowableStyle) from .layout import ContainerOverflow from ....
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/reference.py
0.604516
0.164148
reference.py
pypi
from contextlib import suppress from itertools import chain, takewhile from .attribute import Attribute, Bool, Integer, OverrideDefault from .draw import Line, LineStyle from .element import create_destination from .flowable import GroupedFlowables, StaticGroupedFlowables, WarnFlowable from .flowable import LabeledF...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/structure.py
0.7586
0.22396
structure.py
pypi
from token import LPAR, RPAR from .attribute import Attribute, ParseError from .dimension import Dimension, PT from .element import DocumentElement from .flowable import Flowable, FlowableStyle from .layout import VirtualContainer from .style import StyledMeta from .text import InlineStyle, InlineStyled from .util i...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/inline.py
0.642769
0.236296
inline.py
pypi
from .attribute import Attribute, AcceptNoneAttributeType, ParseError from .color import Color, BLACK, GRAY90 from .style import Style, Styled from .dimension import Dimension, PT __all__ = ['Stroke', 'LineStyle', 'Line', 'ShapeStyle', 'Shape', 'Polygon', 'Rectangle'] class Stroke(AcceptNoneAttributeTy...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/draw.py
0.896984
0.301253
draw.py
pypi
import inspect import re import sys from .attribute import AcceptNoneAttributeType, ParseError from collections import OrderedDict from token import PLUS, MINUS, NUMBER, NAME, OP __all__ = ['Dimension', 'PT', 'PICA', 'INCH', 'MM', 'CM', 'PERCENT', 'QUARTERS'] class DimensionType(type): """Maps compa...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/dimension.py
0.754915
0.42185
dimension.py
pypi
from .annotation import NamedDestination from .warnings import warn __all__ = ['DocumentElement'] class DocumentElement(object): """A element part of the document to be rendered Args: id (str): unique identifier for referencing this element parent (DocumentElement): element of which this ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/element.py
0.814901
0.170439
element.py
pypi
import re from ast import literal_eval from html.entities import name2codepoint from token import NAME, STRING, NEWLINE, LPAR, RPAR, ENDMARKER from .annotation import AnchorAnnotation, LinkAnnotation, AnnotatedSpan from .attribute import (AttributeType, AcceptNoneAttributeType, Attribute, Bool...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/text.py
0.78403
0.154344
text.py
pypi
import os from ast import literal_eval from pathlib import Path from token import LPAR, RPAR, NAME, EQUAL, NUMBER, ENDMARKER, STRING, COMMA from .attribute import (Attribute, AttributesDictionary, OverrideDefault, AcceptNoneAttributeType, OptionSet, Integer, ParseErr...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/image.py
0.822831
0.318194
image.py
pypi
import re from collections import OrderedDict from configparser import ConfigParser from io import StringIO from itertools import chain from pathlib import Path from token import NUMBER, ENDMARKER, MINUS, PLUS, NAME, NEWLINE from tokenize import generate_tokens from warnings import warn from .util import (NamedDesc...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/attribute.py
0.670608
0.182553
attribute.py
pypi
from collections.abc import Iterable from itertools import chain from functools import partial from math import sqrt from token import NAME from .attribute import (Attribute, OptionSet, OverrideDefault, Integer, Bool, AcceptNoneAttributeType, ParseError) from .dimension import DimensionBase a...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/table.py
0.839832
0.20454
table.py
pypi
from collections import deque from contextlib import contextmanager from copy import copy from .dimension import Dimension, PT, DimensionAddition from .util import ContextManager __all__ = ['Container', 'FlowablesContainer', 'ChainedContainer', 'DownExpandingContainer', 'InlineDownExpandingContainer', ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/layout.py
0.825449
0.458773
layout.py
pypi
from .attribute import Attribute, Bool from .flowable import GroupedFlowables, GroupedFlowablesStyle, DummyFlowable from .paragraph import Paragraph from .reference import Reference from .strings import StringField from .structure import Section, Heading, SectionTitles from .style import Styled from .text import Mixe...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/index.py
0.604516
0.216819
index.py
pypi
import os import re import struct from binascii import unhexlify from io import BytesIO from warnings import warn from . import Font, GlyphMetrics, LeafGetter, MissingGlyphException from .mapping import UNICODE_TO_GLYPH_NAME, ENCODINGS from ..font.style import FontVariant, FontWeight, FontSlant, FontWidth from ..u...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/type1.py
0.456652
0.203529
type1.py
pypi
import hashlib, math, io, struct from datetime import datetime, timedelta from collections import OrderedDict from ...util import all_subclasses def create_reader(data_format, process_struct=lambda data: data[0]): data_struct = struct.Struct('>' + data_format) def reader(file, **kwargs): data = dat...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/parse.py
0.642096
0.335079
parse.py
pypi
import struct from binascii import hexlify from io import BytesIO def grab(file, data_format): data = file.read(struct.calcsize(data_format)) return struct.unpack('>' + data_format, data) card8 = lambda file: grab(file, 'B')[0] card16 = lambda file: grab(file, 'h')[0] offsize = card8 def offset(offset_s...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/cff.py
0.476092
0.307501
cff.py
pypi
import struct from .parse import OpenTypeTable, MultiFormatTable, Record from .parse import int16, uint16, ushort, ulong, Packed from .parse import array, context, context_array, indirect, indirect_array from .layout import LayoutTable, Coverage, ClassDefinition, Device from ...util import cached_property class Va...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/gpos.py
0.517083
0.227856
gpos.py
pypi
from .parse import OpenTypeTable, MultiFormatTable from .parse import uint16, ushort, ulong, glyph_id, array, indirect from .parse import context_array, indirect_array from .layout import LayoutTable from .layout import Coverage # Single substitution (subtable format 1) class SingleSubTable(MultiFormatTable): e...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/gsub.py
0.593963
0.255547
gsub.py
pypi
import struct from .parse import OpenTypeTable, MultiFormatTable, Record from .parse import byte, ushort, short, ulong, fixed, fword, ufword, uint24 from .parse import longdatetime, string, array, indirect, context_array, Packed from .macglyphs import MAC_GLYPHS from . import ids class HeadTable(OpenTypeTable): ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/required.py
0.640636
0.251602
required.py
pypi
from .parse import OpenTypeTable, MultiFormatTable, Record, context_array from .parse import fixed, array, uint16, tag, glyph_id, offset, indirect, Packed class ListRecord(Record): entries = [('Tag', tag), ('Offset', offset)] def parse_value(self, file, file_offset, entry_type): self...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/font/opentype/layout.py
0.44071
0.293076
layout.py
pypi
from itertools import chain from ..attribute import AttributesDictionary from ..flowable import StaticGroupedFlowables from ..util import NotImplementedAttribute __all__ = ['TreeNode', 'InlineNode', 'BodyNode', 'BodySubNode', 'GroupingNode', 'DummyNode', 'TreeNodeMeta', 'Reader'] class TreeNode(object...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/__init__.py
0.631481
0.243564
__init__.py
pypi
import re from ... import styleds from ...annotation import HyperLink, NamedDestination from . import EPubInlineNode, EPubBodyNode, EPubGroupingNode class Body(EPubBodyNode): pass class Section(EPubGroupingNode): grouped_flowables_class = styleds.Section class Div(EPubGroupingNode): grouped_flowab...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/epub/nodes.py
0.419648
0.365343
nodes.py
pypi
import os import re from urllib.parse import urljoin from urllib.request import pathname2url from ...styleds import Paragraph from ...text import MixedStyledText from ...util import NotImplementedAttribute from ... import DATA_PATH from .. import (TreeNode, InlineNode, BodyNode, BodySubNode, GroupingNode, ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/xml/__init__.py
0.516108
0.190592
__init__.py
pypi
from . import (DocBookNode, DocBookInlineNode, DocBookBodyNode, DocBookGroupingNode) from ...reference import TITLE, PAGE from ... import styleds class DocumentRoot(DocBookBodyNode): pass class Article(DocumentRoot): pass class Book(DocumentRoot): pass class Info(DocBookBodyNode):...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/docbook/nodes.py
0.544317
0.342187
nodes.py
pypi
import re from datetime import datetime import rinoh as rt from . import (DocutilsInlineNode, DocutilsNode, DocutilsBodyNode, DocutilsGroupingNode, DocutilsDummyNode) from ...dimension import DimensionUnit, INCH, CM, MM, PT, PICA, PERCENT from ...util import intersperse # Support for the following ...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/rst/nodes.py
0.488039
0.254752
nodes.py
pypi
from pathlib import Path from docutils.core import publish_doctree from docutils.io import FileInput from docutils.parsers.rst import Parser as ReStructuredTextParser from ...text import MixedStyledText from .. import (TreeNode, TreeNodeMeta, InlineNode, BodyNode, BodySubNode, GroupingNode, DummyNod...
/rinohtype-0.5.4.tar.gz/rinohtype-0.5.4/src/rinoh/frontend/rst/__init__.py
0.644784
0.21596
__init__.py
pypi