Skip to content

Instantly share code, notes, and snippets.

View kropp's full-sized avatar

Victor Kropp kropp

View GitHub Profile
@kropp
kropp / photo.sh
Created January 19, 2016 15:43
Take a photo with a webcam on Ubuntu
#!/bin/bash
export time=`date +%Y-%m-%d-%H-%M-%S`
export filename="$HOME/photos/photo-$time.jpg"
avconv -f video4linux2 -s 1920x1080 -i /dev/video0 -ss 0:0:0.1 -frames 1 $filename
echo $filename

Keybase proof

I hereby claim:

  • I am kropp on github.
  • I am kropp (https://keybase.io/kropp) on keybase.
  • I have a public key ASDD8kbuBl37-pDgJwh-ktwCQYyognNfSAlyc6Mm3BADpgo

To claim this, I am signing this object:

#include "QMetaTypes.h"
#include "Api.h"
QString jsType(const QString& name);
void generateSignalClasses(QFile &out, const QMetaObject &apiMeta);
void generateParameterList(QFile &out, const QMetaMethod &methodMeta);
void generateApi(QFile &out, const QMetaObject &apiMeta);
int main(int argc, char *argv[]) {
qRegisterMetaTypes();
@kropp
kropp / main.kt
Created February 7, 2019 22:54
X11 app in Kotln/Native
package com.github.kropp
import kotlinx.cinterop.*
import x11.*
const val APPLICATION_NAME = "spotlight"
const val SIZE = 800
@ExperimentalUnsignedTypes
@kropp
kropp / Gtk3Demo.kt
Created May 16, 2017 10:31
GTK+ Demo Application in Kotlin/Native rewritten in OO-style
/*
* Copyright 2010-2017 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
import androidx.compose.foundation.Canvas
import androidx.compose.runtime.Composable
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.remember
import androidx.compose.runtime.setValue
import androidx.compose.runtime.withFrameNanos
import androidx.compose.ui.Modifier
import androidx.compose.ui.geometry.Offset