Skip to content

Instantly share code, notes, and snippets.

View geryxyz's full-sized avatar

Gergő Balogh geryxyz

View GitHub Profile
@geryxyz
geryxyz / README.md
Created March 16, 2021 16:03
sphinx hints

We use and will use the Google style docstring format to document our code. A good place to get familiar with Python documentation: https://www.youtube.com/watch?v=JQ8RQru-Y9Y , most of these are preset to easy execution in this repository, but if you have to or want to change something, it is a good summary about Sphinx.

How to generate developers documentation

You have to be able to execute the code in order to generate the documentations, since it will be imported and analysed during the generation.

<UserControl x:Class="FilterGrid.DropPanel"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:FilterGrid"
mc:Ignorable="d">
<UserControl.Template>
<ControlTemplate TargetType="UserControl">
<Menu>
<Window x:Class="TestFilterGrid.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:TestFilterGrid" xmlns:filtergrid="clr-namespace:FilterGrid;assembly=FilterGrid"
mc:Ignorable="d"
Title="MainWindow" Height="450" Width="800">
<Grid>
<filtergrid:FilterGrid DataContext="{Binding Data}" ItemsSource="{Binding}" AutoGenerateColumns="False">
*.unity -text merge=unity diff
*.prefab -text merge=unity diff
*.asset -text merge=unity diff
def extract(index, of):
return [item[index] for item in of]
public class Out<TValue> {
private TValue value;
public TValue getValue() {
return value;
}
public void setValue(TValue value) {
this.value = value;
}
@geryxyz
geryxyz / speed.py
Created April 6, 2019 20:25
Setting speed for CNC *.tap file in a banch, it will change all F instruction with the new specified speed and create a new file. It scan the current working directory and will process all *.tap expect the results of previous execution.
import sys
import re
import glob
import os.path
import pdb
speed = int(sys.argv[1])
files = glob.glob("*.tap")
for original in files:
exts = os.path.splitext(original)
package org.eclipse.sed.ifl.util.profile;
public class NanoWatch {
private long past = System.nanoTime();
private String name;
public NanoWatch(String name) {
this.name = name;
}
@geryxyz
geryxyz / EU.java
Last active November 8, 2018 15:07
ExceptionUtil
package org.eclipse.sed.ifl.util.exception;
public class EU extends ExceptionUtil {
}
package org.eclipse.sed.ifl.util.wrapper;
public class Defineable<TValue> {
private TValue value;
public Defineable(TValue value) {
this.setValue(value);
}
public TValue getValue() {