Giter Site home page Giter Site logo

michael19 / qt-yandextranslate Goto Github PK

View Code? Open in Web Editor NEW

This project forked from artemyev-sergei/qt-yandextranslate

0.0 2.0 0.0 42 KB

A library to work with Yandex Translate API and Dictionary API in C++ using Qt

License: GNU General Public License v3.0

QMake 2.06% C++ 97.94%

qt-yandextranslate's Introduction

Qt-YandexTranslate

This project is dedicated to those who want to understand how to work with the Yandex.Translate API and Yandex.Dictionary API in Qt using C++. Inasmuch as the project is for educational purposes mainly, I will probably add some new code from time to time to the project if it helps you (and me!) to undestand some peculiarities of both Qt and C++. In fact, I use this project for different experiments with Git as well.

Overview

Here is the list of what you can do using this code in your own application:

  • Get a list of supported languages
  • Get a list of supported translation directions
  • Get a dictionary entry for a word or a phrase
  • Detect the language
  • Translate text

Generally speaking, the project features are:

Getting Started and Tips

Let's assume that you cloned the repository and opened the project in Qt Creator.

Then, first of all, make sure you have acquired your API keys and you have filled empty spaces in the corresponding header files with data. For example, in translate_api.h you will find the following line where you should put your API key:

QString trnsl_api_key = ""; // Put your Translate API key here.

That's basically everything you need to do before building and runnning the project successfully.

The dictionary_api.h and dictionary_api.cpp files represent how Yandex.Dictionary API support was implemented.

Thee translate_api.h and translate_api.cpp files represent how Yandex.Translate API support was implemented.

The mainwindow.h and mainwindow.cpp files represent an example of libraries usage with GUI.

I used JSON interface to access the APIs, therefore you can see how to parse JSON using Qt.

I think there's a lot of space for improvement, therefore if you have any questions or suggestions, feel free to contact me about them!

Powered by Yandex.Translate

qt-yandextranslate's People

Contributors

artemyev-sergei avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.